ChainUtils

Chain helpers internal library

ARBITRUM_MAINNET

uint256 ARBITRUM_MAINNET

ARBITRUM_SEPOLIA

uint256 ARBITRUM_SEPOLIA

POLYGON_MAINNET

uint256 POLYGON_MAINNET

TESTNET

uint256 TESTNET

Overflow

error Overflow()

getBlockNumber

Returns the current block number (l2 block for arbitrum)

getUint48BlockNumber

Returns blockNumber converted to uint48

Parameters

Name
Type
Description

blockNumber

uint256

block number to convert

getWrappedNativeToken

Returns the wrapped native token address for the current chain

isWrappedNativeToken

Returns whether a token is the wrapped native token for the current chain

Parameters

Name
Type
Description

_token

address

token address to check

Was this helpful?