Decimal.js: Detailed Overview & Metrics

v10.4.3(almost 2 years ago)

This package was last published over a year ago. It may not be actively maintained.Types definitions are bundled with the npm packageNumber of direct dependencies: 0Monthly npm downloads

Decimal.js is a JavaScript library for arbitrary-precision decimal and non-decimal arithmetic. It allows precise handling of decimal numbers without the limitations of native JavaScript number handling, ensuring accurate calculations even with very large or very small numbers. Decimal.js provides a rich set of mathematical operations and functions for working with decimal numbers, making it ideal for financial calculations, scientific computations, and any application requiring high precision arithmetic.

Compared to native JavaScript number handling, Decimal.js offers better control over precision, rounding, and arithmetic operations. It is actively maintained and well-documented, ensuring reliability and continued support for developers.

Alternatives:
big.js+
bignumber.js+
mathjs+
decimal.js-light+
jsbi+
big-integer+
bignum+
long+
bigdecimal+
big.js-light+

Tags: javascriptarbitrary-precisiondecimal-arithmeticmathematicsfinancial-calculations