💱Use this hook to get all active bids for the current user.


Authentication required to use this hook

The useActiveBids hook will return all active bids from the current user based on the userId by calling the MarketplaceAuctionBid API.

Hooks Sample Code

import useActiveBids from "mojito-hooks/useActiveBids";

function App {
    const { activeBids, isLoading } = useActiveBids();

    if(isLoading) return <Loader />;

    if(activeBids) return (
            { => <DrawActiveBid bid={bid} />)}

    return <div>No active bids available</div>



This hook doesn't accept any parameters.


activeBidsList of the active bids for the current user.MojitoMarketplaceAuctionBid[]
isLoadingDisplay request loading status, provided for convenience.Boolean
errorThe error object for the query, if an error was thrown.Error
refetchA function to manually refetch the query.(options: T) => Promise<U>
queryResultOriginal React-Query query result.QueryResult<T>