setVotingPeriod

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

Example

import { setVotingPeriod } from "thirdweb/extensions/vote";
const transaction = setVotingPeriod({
contract,
newVotingPeriod: ...,
overrides: {
...
}
});
// Send the transaction
...
function setVotingPeriod(
| { asyncParams: () => Promise<SetVotingPeriodParams> }
>,

Parameters

The options for the "setVotingPeriod" function.

Type

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

Returns

let returnType: PreparedTransaction<
any,
AbiFunction,
>;

A prepared transaction object.