useSignatureDrop
Deprecated
This hook is deprecated and will be removed in a future major version. You should use useContract instead.
- const signatureDrop = useSignatureDrop("0x1234...");
+ const signatureDrop = useContract("0x1234...", "signature-drop").contract;
Hook for getting an instance of an SignatureDrop
contract. This contract is meant to interface with ERC721 compliant NFTs that can be lazily minted.
function useSignatureDrop(
contractAddress?: RequiredParam<string>,
): undefined | SignatureDrop;
Parameters
Returns
type ReturnType = undefined | SignatureDrop;
Example
import { useContract } from '@thirdweb-dev/react'
export default function Component() {
const { contract } = useContract("<YOUR-CONTRACT-ADDRESS>", "signature-drop")
// Now you can use the Signature drop contract in the rest of the component
// For example, this function will let the connected wallet claim a new NFT
async function claim(quantity) {
await contract.claim(quantity)
}
...
}