gweiToEther
gweiToEther(
gweiQuantity):string
Defined in: utils/gwei-to-ether.ts:20
Convert from Gwei to Ether
No direct equivalent in ethers.js; requires multiple functions to achieve.
No direct equivalent in web3; requires multiple functions to achieve.
Parameters
gweiQuantity
the amount of gwei to convert to ether
string | number | bigint
Returns
string
a string decimal representation of ether equivalent to the specified gwei
Example
gweiToEther('1000000000000')// '1000'gweiToEther(1000000000000)// '1000'