Node icon indicating copy to clipboard operation
Node copied to clipboard

Unit Representation for different currency values

Open utkarshg6 opened this issue 1 year ago • 0 comments

We want a better method to represent balances.

For example:

- 10,000,000,000 wei can be represented as 10 gwei.
- 10,634,509,800 gwei can be represented as 10.634 Eth
-  123,987,621 wei can be represented as 0.123 gwei

We can use a U256 to store the number in Wei and then divide by billion as many times as it's required to get the unit we need.

utkarshg6 avatar Nov 13 '24 08:11 utkarshg6