Documentation Index
Fetch the complete documentation index at: https://docs.transmissions.wtf/llms.txt
Use this file to discover all available pages before exploring further.
Usage
"use client";
import { useCreateToken } from "@tx-kit/hooks";
const MyComponent = () => {
const {
createToken,
tokenId,
status,
txHash,
error
} = useCreateToken()
const onClick = () => {
createToken({ ... })
}
return <button onClick={onClick}>Create Token</button>
}
Returns
createToken
Function to create a new token. See createToken args.
- type:
({ channelAddress: string; uri: string; maxSupply: bigint; transactionOverrides?: TransactionOverrides; }) => Promise<Log[] | undefined>
status
- type:
ContractExecutionStatus
type ContractExecutionStatus =
| 'pendingApproval'
| 'txInProgress'
| 'complete'
| 'error'
the status of the transaction
tokenId
the token id of the new token
txHash
the transaction hash of the transaction
error
the revert message if the transaction fails