castVoteWithReason

Prepares a transaction to call the "castVoteWithReason" function on the contract.

Example

import { castVoteWithReason } from "thirdweb/extensions/vote";
const transaction = castVoteWithReason({
contract,
proposalId: ...,
support: ...,
reason: ...,
overrides: {
...
}
});
// Send the transaction
...
function castVoteWithReason(
| { asyncParams: () => Promise<CastVoteWithReasonParams> }
>,

Parameters

The options for the "castVoteWithReason" function.

Type

| { asyncParams: () => Promise<CastVoteWithReasonParams> }
>;

Returns

let returnType: PreparedTransaction<
any,
AbiFunction,
>;

A prepared transaction object.