I am trying to get the balance of eth from Metamask account, but I get the following error in the browser console:
Uncaught Error: [number-to-bn] while converting number "0.322778986" to BN.js instance, error: invalid number value. Value must be an integer, hex string, BN or BigNumber instance. Note, decimals are not supported.
This is the code for retrieving the eth value :
Balance: {this.props.ethBalance ? window.web3.utils.fromWei(this.props.ethBalance.toString(), 'ether') : ''}
How can I convert it to BN in order to display the value? Any help would be appreciated!