- 30/04/26
- #401
BigNumber.sum: return zero if there are no arguments. - #352 Add
toBigIntmethod. - #286 Add
fromFormatmethod. - #262
decimalPlaces,toFixedandtoFormat: support negative decimal places. - #260
toFormat: support minimum/maximum decimal places. toFormat: fallback toFORMATfor each property not inoptions.- [BUGFIX] #342 Large
DECIMAL_PLACEScausing slow hex integer base conversion. - Typescript: add test_api.ts to improved typed API test coverage.
- 14/04/26
- Add
STRICTconfiguration option: iftrue(default), throw an exception on invalid input. iffalse, returnNaNon invalid input. toFraction: return[1, 0]forInfinityand[0, 0]forNaN.- Support underscores as separators.
- If a base is supplied, reject non-finite values and base prefixes.
- 24/02/26
- Reinstate README.md links.
- 24/02/26
- Commit dist folder.
- 23/02/26
- Implement targeted builds for ES modules, CommonJS, and browser (global assignment).
- Add CI workflow.
- Add type declaration import tests.
- Remove
BigNumber.DEBUG, so the behaviour is now always as if it wastrue: throw on invalid input instead of returningNaN, and always validate thec,e, andsproperties of objects passed toisBigNumber - Don't call
toStringon any arbitrary object passed to the constructor. - Require a BigNumber value to be a string if a base is also passed.
- Add
toObjectprototype method which returns a plain object withc,e, andsproperties. - Remove .npmignore, as
filesin package.json is used. Add .gitignore. - Normalise line endings and add .gitattributes.
- Add typescript to
devDependencies.
- 11/07/25
- [BUGFIX] #388
toPrecisionfix.
- 19/04/25
- Refactor type declarations:
- Rename bignumber.d.ts to types.d.ts.
- Rename bignumber.d.cts to bignumber.d.ts.
- Add
export as namespaceto bignumber.d.ts. - Remove subpath exports from package.json.
- Refactor named export from bignumber.d.mts.
- #383 Remove
?from staticBigNumberanddefaultproperties. - Add blank lines after titles in CHANGELOG.md.
- 08/04/25
- #371 #382 Add
BigNumberas named export.
- 03/04/25
- #355 Support
BigIntargument. - #371 Provide separate type definitions for CommonJS and ES modules.
- #374 Correct
comparedToreturn type.
- 28/08/23
- #354 Amend
roundto avoid bug in v8 Maglev compiler. - [BUGFIX] #344
minimum(0, -0)should be-0.
- 04/12/22
- #338 [BUGFIX]
exponentiatedBy: ensure0**-n === Infinityfor very largen.
- 08/08/22
- #329 Remove
importexample. - #277 Resolve lint warnings and add number
toStringnote. - Correct
decimalPlaces()return type in bignumber.d.ts. - Add ES module global
cryptoexample. - #322 Add
exportsfield to package.json. - #251 (#308) Amend bignumber.d.ts to allow instantiating a BigNumber without
new.
- 12/12/21
- #250 [BUGFIX] Allow use of user-defined alphabet for base 10.
- #295 Remove bignumber.min.js and amend README.md.
- Update .travis.yml and LICENCE.md.
- 28/09/20
- [BUGFIX] #276 Correct
sqrtinitial estimate. - Update .travis.yml, LICENCE.md and README.md.
- 27/05/2019
- For compatibility with legacy browsers, remove
Symbolreferences.
- 24/02/2019
- [BUGFIX] #222 Restore missing
vartoexport BigNumber. - Allow any key in BigNumber.Instance in bignumber.d.ts.
- 23/02/2019
- [NEW FEATURE] #220 Create a BigNumber using
{s, e, c}. - [NEW FEATURE]
isBigNumber: ifBigNumber.DEBUGistrue, also check that the BigNumber instance is well-formed. - Remove
instanceofchecks; just use_isBigNumberto identify a BigNumber instance. - Add
_isBigNumberto prototype in bignumber.mjs. - Add tests for BigNumber creation from object.
- Update API.html.
- 13/01/2019
- #209
toPrecisionwithout argument should followtoString. - Improve Use section of README.
- Optimise
toString(10). - Add verson number to API doc.
- 01/11/2018
- Rest parameter must be array type in bignumber.d.ts.
- 01/11/2018
- [NEW FEATURE] Add
BigNumber.summethod. - [NEW FEATURE]
toFormat: addprefixandsuffixoptions. - [NEW FEATURE] #178 Pass custom formatting to
toFormat. - [BREAKING CHANGE] #184
toFraction: return array of BigNumbers not strings. - [NEW FEATURE] #185 Enable overwrite of
valueOfto prevent accidental addition to string. - #183 Add Node.js
cryptorequirement to documentation. - [BREAKING CHANGE] #198 Disallow signs and whitespace in custom alphabet.
- [NEW FEATURE] #188 Implement
util.inspect.customfor Node.js REPL. - #170 Make
isBigNumbera type guard in bignumber.d.ts. - [BREAKING CHANGE]
BigNumber.minandBigNumber.max: don't accept an array. - Update .travis.yml.
- Remove bower.json.
- 24/05/2018
- Add
browserfield to package.json.
- 22/05/2018
- #166 Correct .mjs file. Remove extension from
mainfield in package.json.
- 18/05/2018
- Add
modulefield to package.json for bignumber.mjs.
- 17/05/2018
- #165 Bugfix: upper-case letters for bases 11-36 in a custom alphabet.
- Add note to README regarding creating BigNumbers from Number values.
- 26/04/2018
- #158 Fix global object variable name typo.
- 26/04/2018
- #143 Remove global BigNumber from typings.
- #144 Enable compatibility with
Object.freeze(Object.prototype). - #148 #123 #11 Only throw on a number primitive with more than 15 significant digits if
BigNumber.DEBUGistrue. - Only throw on an invalid BigNumber value if
BigNumber.DEBUGistrue. Return BigNumberNaNinstead. - #154
exponentiatedBy: allow BigNumber exponent. - #156 Prevent Content Security Policy unsafe-eval issue.
toFraction: allowInfinitymaximum denominator.- Comment-out some excess tests to reduce test time.
- Amend indentation and other spacing.
- 26/01/2018
- #137 Implement
APLHABETconfiguration option. - Remove
ERRORSconfiguration option. - Remove
toDigitsmethod; extendprecisionmethod accordingly. - Remove s
roundmethod; extenddecimalPlacesmethod accordingly. - Remove methods:
ceil,floor, andtruncated. - Remove method aliases:
add,cmp,isInt,isNeg,trunc,mul,negandsub. - Rename methods:
shifttoshiftedBy,anothertoclone,toPowertoexponentiatedBy, andequalstoisEqualTo. - Rename methods: add
isprefix togreaterThan,greaterThanOrEqualTo,lessThanandlessThanOrEqualTo. - Add methods:
multipliedBy,isBigNumber,isPositive,integerValue,maximumandminimum. - Refactor test suite.
- Add CHANGELOG.md.
- Rewrite bignumber.d.ts.
- Redo API image.
- 27/11/2017
- #81 Don't throw on constructor call without
new.
- 26/09/2017
- Remove node 0.6 from .travis.yml.
- Add bignumber.mjs.
- 03/09/2017
- Add missing aliases to bignumber.d.ts.
- 30/08/2017
- Add types: bignumber.d.ts.
- 03/05/2017
- #120 Workaround Safari/Webkit bug.
- 05/04/2017
- #121 BigNumber.default to BigNumber['default'].
- 09/01/2017
- Replace BigNumber.isBigNumber method with isBigNumber prototype property.
- 08/01/2017
- Minor documentation edit.
- 08/01/2017
- Uncomment
isBigNumbertests. - Ignore dot files.
- 08/01/2017
- Add
isBigNumbermethod.
- 08/01/2017
- Bugfix: Possible incorrect value of
ERRORSafter aBigNumber.anothercall (due toparseNumericdeclaration in outer scope).
- 23/11/2016
- Apply fix for old ipads with
%issue, see #57 and #102. - Correct error message.
- 09/11/2016
- Remove
require('crypto')- leave it to the user. - Add
BigNumber.setasBigNumber.configalias. - Default
POW_PRECISIONto0.
- 14/07/2016
- #97 Add exports to support ES6 imports.
- 07/03/2016
- #86 Add modulus parameter to
toPower.
- 03/03/2016
- #91 Permit larger JS integers.
- 15/12/2015
- Correct UMD.
- 13/12/2015
- Refactor re global object and crypto availability when bundling.
- 10/12/2015
- Bugfix:
window.cryptonot assigned tocrypto.
- 09/12/2015
- Prevent code bundler from adding
cryptoshim.
- 26/10/2015
- For
valueOfandtoJSON, include the minus sign with negative zero.
- 2/10/2015
- Internal round function bugfix.
- 31/03/2015
- Add bower.json. Tweak division after in-depth review.
- 25/03/2015
- Amend README. Remove bitcoin address.
- 25/03/2015
- Critical bugfix #58: division.
- 18/02/2015
- Amend README. Add source map.
- 18/02/2015
- Correct links.
- 18/02/2015
- Add
max,min,precision,random,shiftedBy,toDigitsandtruncatedmethods. - Add the short-forms:
add,mul,sd,subandtrunc. - Add an
anothermethod to enable multiple independent constructors to be created. - Add support for the base 2, 8 and 16 prefixes
0b,0oand0x. - Enable a rounding mode to be specified as a second parameter to
toExponential,toFixed,toFormatandtoPrecision. - Add a
CRYPTOconfiguration property so cryptographically-secure pseudo-random number generation can be specified. - Add a
MODULO_MODEconfiguration property to enable the rounding mode used by themodulooperation to be specified. - Add a
POW_PRECISIONconfiguration property to enable the number of significant digits calculated by the power operation to be limited. - Improve code quality.
- Improve documentation.
- 29/12/2014
- Add
dividedToIntegerBy,isIntegerandtoFormatmethods. - Remove the following short-forms:
isF,isZ,toE,toF,toFr,toN,toP,toS. - Store a BigNumber's coefficient in base 1e14, rather than base 10.
- Add fast path for integers to BigNumber constructor.
- Incorporate the library into the online documentation.
- 13/11/2014
- Add
toJSONanddecimalPlacesmethods.
- 08/06/2014
- Amend README.
- 08/05/2014
- Add
toNumber.
- 08/11/2013
- Ensure correct rounding of
sqrtin all, rather than almost all, cases. - Maximum radix to 64.
- 17/10/2013
- Sign of zero when x < 0 and x + (-x) = 0.
- 19/9/2013
- Throw Error objects for stack.
- 22/8/2013
- Show original value in constructor error message.
- 1/8/2013
- Allow numbers with trailing radix point.
- Bugfix: error messages with incorrect method name
- 8/11/2012
- Initial release