AbiItem.getSignature
Computes the stringified signature for a given AbiItem.AbiItem
.
Imports
Named
import { AbiItem } from 'ox'
Examples
import { AbiItem } from 'ox'
const signature = AbiItem.getSignature('function ownerOf(uint256 tokenId)')
'ownerOf(uint256)'
import { AbiItem } from 'ox'
const signature = AbiItem.getSignature({
name: 'ownerOf',
type: 'function',
inputs: [{ name: 'tokenId', type: 'uint256' }],
outputs: [],
stateMutability: 'view',
})
'ownerOf(uint256)'
Definition
function getSignature(
abiItem: string | AbiItem,
): string
Source: src/core/AbiItem.ts
Parameters
abiItem
- Type:
string | AbiItem
The ABI Item to compute the signature for.
Return Type
The stringified signature of the ABI Item.
string