Function useRevealLazyMint

  • Beta

    Reveal a batch of delayed reveal NFTs

    Type Parameters

    Parameters

    Returns UseMutationResult<Omit<{
        data: (() => Promise<unknown>);
        receipt: providers.TransactionReceipt;
    }, "data">, unknown, RevealLazyMintInput, unknown>

    a mutation object that can be used to reveal a batch of delayed reveal NFTs

    Example

    const Component = () => {
    const { contract } = useContract("{{contract_address}}");
    const {
    mutate: revealLazyMint,
    isLoading,
    error,
    } = useRevealLazyMint(contract);

    if (error) {
    console.error("failed to reveal batch", error);
    }

    return (
    <button
    disabled={isLoading}
    onClick={() => revealLazyMint({ batchId: "0", password: "my-password" })}
    >
    Reveal batch!
    </button>
    );
    };

    Twfeature

    ERC721Revealable | ERC1155Revealable

    See

    Documentation

Generated using TypeDoc