transferOwnership

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

Example

import { transferOwnership } from "thirdweb/extensions/modular";
const transaction = transferOwnership({
contract,
newOwner: ...,
overrides: {
...
}
});
// Send the transaction
...
function transferOwnership(
| { asyncParams: () => Promise<TransferOwnershipParams> }
>,

Parameters

The options for the "transferOwnership" function.

Type

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

Returns

let returnType: PreparedTransaction<
any,
AbiFunction,
>;

A prepared transaction object.