foundry icon indicating copy to clipboard operation
foundry copied to clipboard

feat(cast): add flag equivalents of `parseUnits`, `formatUnits`

Open 0xdapper opened this issue 4 months ago • 0 comments

Component

Cast

Describe the feature you would like

cast --from-wei <wei> is equivalent to parseEther cast --to-wei <ether> is equivalent to formatEther

However, cast --to-unit is not equivalents of the more generic parseUnits. It only supports parsing to wei, gwei, ether, not to arbitrary decimals.

I couldn't find a cast --from-unit altogether.

This feature request is to add functionality to parse and format numbers to arbitrary decimals.

Additional context

No response

0xdapper avatar Oct 04 '24 10:10 0xdapper