toWei static method
Converts the specified Ethereum amount in decimal string format to Wei.
The amount
parameter is expected to be a string representation of an
Ethereum amount, and the result is returned as a BigInt representing the
equivalent value in Wei.
Implementation
static BigInt toWei(String amount) {
final parse = BigRational.parseDecimal(amount);
return (parse * _ethDecimal).toBigInt();
}