Convert a Decimal to a string representation. Uses toFixed() to ensure consistent string output without scientific notation.
The Decimal instance to convert
String representation of the decimal value
const d = new Decimal("0.000000001");console.log(decimalToString(d)); // "0.000000001" (not "1e-9") Copy
const d = new Decimal("0.000000001");console.log(decimalToString(d)); // "0.000000001" (not "1e-9")
Convert a Decimal to a string representation. Uses toFixed() to ensure consistent string output without scientific notation.