Decodes the result of a function call.
import { decodeFunctionResult } from "thirdweb/utils"; const data = "0x...";const result = await decodeFunctionResult({ contract, data });
function decodeFunctionResult(options: { contract: Readonly<ContractOptions<abi>>; data: `0x${string}`;}): Promise< ReturnType< ReturnType<abi, Name<abi>, undefined, AbiFunction>, "Array" >>;
The options object.
let options: { contract: Readonly<ContractOptions<abi>>; data: `0x${string}`;};
let returnType: Promise< ReturnType< ReturnType<abi, Name<abi>, undefined, AbiFunction>, "Array" >>;
The decoded result.