Maximum exponent before overflow to Infinity. Integer from 0 to Decimal.limits.maxExponent; defaults to Decimal.limits.maxExponent.
Maximum mantissa digits emitted by a public string-formatting operation. Integer from 1 to Decimal.limits.maxDigits; defaults to 1_000_000.
Maximum decimal coefficient digits generated while parsing a prefixed number. Integer from 1 to Decimal.limits.maxDigits; defaults to 1_000_000.
Minimum exponent before underflow to zero. Integer from -Decimal.limits.maxExponent to 0; defaults to -Decimal.limits.maxExponent.
Quotient rounding rule used by mod(). Defaults to 'down', matching JavaScript remainder semantics.
For a.mod(n), the quotient q = a / n is rounded according to the selected
mode, then the remainder is calculated as r = a - n * q.
Maximum significant digits in calculation and base-conversion results. Integer from 1 to Decimal.limits.maxDigits; defaults to 20.
Rounding mode used to round to precision when a method does not receive an explicit mode. Defaults to 'half-up'.
Exponent at or below which toString uses exponential notation. Integer from -Decimal.limits.maxExponent to 0; defaults to -7.
const SmallExponent = Decimal.clone({ toExpNeg: -5 })
SmallExponent.config.toExpNeg // -5
new SmallExponent('9.999e-4').toString() // '0.0009999'
new SmallExponent('1e-5').toString() // '1e-5'
const AlwaysExponential = Decimal.clone({ toExpNeg: 0 })
new AlwaysExponential('0.5').toString() // '5e-1'
Exponent at or above which toString uses exponential notation. Integer from 0 to Decimal.limits.maxExponent; defaults to 21.
Complete configuration attached independently to each Decimal constructor. Read the current frozen snapshot through
Decimal.config; assign a DecimalConfigInput to update selected settings.