useEcdsaInitCodeHash
Init-code hash of the ECDSA proxy the factory would deploy for mode.
@tokenops/sdk/fhe-airdrop/advanced/react{ data, isLoading, error, refetch }Description
Init-code hash of the ECDSA proxy the factory would deploy for mode.
The hash tracks the factory's current implementation pointer, so it exists
to bracket a prediction for freshness: read it before a campaign build and
again after, and a change between the two means an implementation swap
landed mid-flight and every address derived from
usePredictEcdsaAirdropAddress is stale. Feed the first observation
to usePreflightCreateAirdrop's expectedInitCodeHash to have the drift
check made for you.
Lives on /advanced/react beside the predict hooks rather than the
headline subpath: on its own the hash answers nothing a UI can act on.
Signature
function useEcdsaInitCodeHash(args: UseEcdsaInitCodeHashArgs): UseQueryResult<Hex, Error>;Parameters
Shape of the options object passed to the hook itself.
| Property | Type | Description |
|---|---|---|
| paramsrequired | EcdsaAirdropParams | |
| moderequired | DeploymentMode |
Example
const before = useEcdsaInitCodeHash({ params, mode: "clone" });Pulled directly from the hook's TSDoc block — the same snippet your IDE shows on hover.
See also
Other Introspection hooks in airdrop v2:
usePredictEcdsaAirdropAddressWhere an ECDSA create* from deployer with this (mode, userSalt) pair would land.usePredictMerkleAirdropAddressWhere a Merkle create* from deployer with this (mode, userSalt) pair would land.useFactoryRoleConstantsRead the factory's role identifiers in one fan-out.useMerkleInitCodeHashInit-code hash of the Merkle proxy the factory would deploy for mode - the Merkle counterpart of useEcdsaInitCodeHash, with the same before/after bracketing job and the same /advanced/react home.