web3-react icon indicating copy to clipboard operation
web3-react copied to clipboard

Can not use {error} in useWeb3React from '@web3-react/core'

Open ducndt opened this issue 2 years ago • 0 comments

i have const { error } = useWeb3React(); to catch error when switch chain network or reject transaction,... If reject connect, it will throw error UserRejectedRequestErrorWalletConnect successfull. But when i switch to unsupported chainId, it can not throw error UnsupportedChainIdError. How can i do or how can i catch this error. I follow this example 1 in this https://www.programcreek.com/javascript/?api=%40web3-react%2Fcore.UnsupportedChainIdError

ducndt avatar May 12 '23 04:05 ducndt