Docs

useTotalCount

Hook to get the total count of unique NFTs minted on a smart contract.

Available to use on smart contracts that implement the ERC721 or ERC1155 standard.

When used for ERC1155 contracts, the total count is the number of unique token IDs minted, not the total supply of all tokens in circulation.

Example

import { useTotalCount, useContract } from "@thirdweb-dev/react";
function App() {
const { contract } = useContract(contractAddress);
const { data: totalCount, isLoading, error } = useTotalCount(contract);
}

Parameters

Returns

A BigNumber that includes the total count of NFTs