TokenAmount
The Token Amount component is used to display a token logo followed by an amount and the token symbol.
Usage
Demonstration
Props
address
address
The address of the token contract, on the specified chainId
(only Ethereum Mainnet is supported at the moment).
amount
amount
The token amount.
chainId
chainId
The chain ID for the token. Only Ethereum Mainnet (1
) is supported at the moment.
decimals
decimals
The number of decimals for the token amount, as specified by the token contract.
digits
digits
Rounds the number to a given decimal place.
iconUrl
iconUrl
Overrides the icon URL given by the token address.
size
size
Size of the component.
symbol
symbol
Overrides the symbol given by the token address.
Last updated