{"_id":"@formatjs/bigdecimal","_rev":"4424162","name":"@formatjs/bigdecimal","description":"BigInt-backed decimal arithmetic for ECMA-402 polyfills","dist-tags":{"latest":"0.2.0"},"maintainers":[{"name":"longlho","email":"holevietlong@gmail.com"},{"name":"pyrocat","email":"dinglinjie@gmail.com"},{"name":"redonkulus","email":"seth@bertalotto.net"}],"time":{"modified":"2026-04-08T13:49:19.000Z","created":"2026-03-17T17:06:14.131Z","0.2.0":"2026-03-19T01:48:11.656Z","0.1.0":"2026-03-17T17:06:14.131Z"},"users":{},"author":{"name":"Long Ho","email":"holevietlong@gmail.com"},"repository":{"type":"git","url":"git+https://github.com/formatjs/formatjs.git"},"versions":{"0.2.0":{"name":"@formatjs/bigdecimal","description":"BigInt-backed decimal arithmetic for ECMA-402 polyfills","version":"0.2.0","license":"MIT","author":{"name":"Long Ho","email":"holevietlong@gmail.com"},"type":"module","sideEffects":false,"types":"index.d.ts","exports":{".":"./index.js"},"dependencies":{},"bugs":{"url":"https://github.com/formatjs/formatjs/issues"},"homepage":"https://github.com/formatjs/formatjs#readme","keywords":["bigdecimal","bigint","decimal","ecma402","i18n","intl"],"repository":{"type":"git","url":"git+https://github.com/formatjs/formatjs.git"},"_id":"@formatjs/bigdecimal@0.2.0","_integrity":"sha512-GeaxHZbUoYvHL9tC5eltHLs+1zU70aPw0s7LwqgktIzF5oMhNY4o4deEtusJMsq7WFJF3Ye2zQEzdG8beVk73w==","_resolved":"/tmp/8780241774f967410a84df785a0a9e2d/formatjs-bigdecimal-0.2.0.tgz","_from":"file:formatjs-bigdecimal-0.2.0.tgz","_nodeVersion":"24.14.0","_npmVersion":"11.9.0","dist":{"shasum":"84b8293eab6113d436f27a56691975c86eecbaa4","size":6063,"noattachment":false,"key":"/@formatjs/bigdecimal/-/@formatjs/bigdecimal-0.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/@formatjs/bigdecimal/download/@formatjs/bigdecimal-0.2.0.tgz"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:755dd2f3-fe8d-4c89-bb6c-4ef39152eb75"}},"directories":{},"maintainers":[{"name":"longlho","email":"holevietlong@gmail.com"},{"name":"pyrocat","email":"dinglinjie@gmail.com"},{"name":"redonkulus","email":"seth@bertalotto.net"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/bigdecimal_0.2.0_1773884891504_0.9683200997846115"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-03-19T01:48:11.656Z","publish_time":1773884891656,"_source_registry_name":"default","_cnpm_publish_time":1773884891656},"0.1.0":{"name":"@formatjs/bigdecimal","version":"0.1.0","keywords":["bigdecimal","bigint","decimal","ecma402","i18n","intl"],"author":{"name":"Long Ho","email":"holevietlong@gmail.com"},"license":"MIT","_id":"@formatjs/bigdecimal@0.1.0","maintainers":[{"name":"longlho","email":"holevietlong@gmail.com"},{"name":"pyrocat","email":"dinglinjie@gmail.com"},{"name":"redonkulus","email":"seth@bertalotto.net"}],"homepage":"https://github.com/formatjs/formatjs#readme","bugs":{"url":"https://github.com/formatjs/formatjs/issues"},"dist":{"shasum":"6d55ec204e388c17c0ec236a8ea549b43f839b16","size":5893,"noattachment":false,"key":"/@formatjs/bigdecimal/-/@formatjs/bigdecimal-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/@formatjs/bigdecimal/download/@formatjs/bigdecimal-0.1.0.tgz"},"type":"module","types":"index.d.ts","exports":{".":"./index.js"},"gitHead":"3e554b07e572cf99f0c5e39a858ec14323103365","_npmUser":{"name":"longlho","email":"holevietlong@gmail.com"},"repository":{"url":"git+https://github.com/formatjs/formatjs.git","type":"git"},"_npmVersion":"11.6.2","description":"BigInt-backed decimal arithmetic for ECMA-402 polyfills","directories":{},"sideEffects":false,"_nodeVersion":"24.13.0","dependencies":{},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/bigdecimal_0.1.0_1773767173954_0.6738584288398908","host":"s3://npm-registry-packages-npm-production"},"_cnpmcore_publish_time":"2026-03-17T17:06:14.131Z","publish_time":1773767174131,"_source_registry_name":"default","_cnpm_publish_time":1773767174131}},"readme":"# @formatjs/bigdecimal\n\nBigInt-backed decimal arithmetic library designed as a lightweight replacement for `decimal.js` in ECMA-402 polyfills.\n\n## Representation\n\nValues are represented as `mantissa × 10^exponent` where:\n\n- `mantissa` is a `bigint` (signed, normalized — no trailing zeros)\n- `exponent` is a `number` (integer scaling factor)\n- Special flags handle NaN, ±Infinity, and -0\n\n## API\n\nImplements the 27 methods used by `@formatjs/ecma402-abstract`:\n\n- **Arithmetic**: `times`, `div`, `plus`, `minus`, `mod`, `abs`, `negated`, `pow`, `floor`, `ceil`, `log`\n- **Comparison**: `eq`, `lessThan`, `greaterThan`, `lessThanOrEqualTo`, `greaterThanOrEqualTo`\n- **Queries**: `isZero`, `isNaN`, `isFinite`, `isNegative`, `isPositive`, `isInteger`\n- **Conversion**: `toNumber`, `toString`\n- **Static**: `BigDecimal.pow`, `BigDecimal.set`\n","_attachments":{},"homepage":"https://github.com/formatjs/formatjs#readme","bugs":{"url":"https://github.com/formatjs/formatjs/issues"},"license":"MIT"}