Should/does the "number" package support bigints? #3424
Replies: 1 comment 1 reply
-
|
The original idea of the "number" package to have a lightweight solution for a very common need, namely having a parser and a set of functions to evaluate basic maths. The lightweight version does not include big classes like I think adding We're making plans and prototypes for a refactored core of the library. I hope that will make it trivial to just pick the functions and datatypes that you need, making it easier to roll your own "number only" package, or roll your own "number and bigint only" package if that is what you need. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Right now, the mathjs library comes in two flavors: the "full" one that has Fraction and Complex and BigNumber support, and the "number" one that "just supports numbers". But the latter doesn't really "just support numbers" -- it allows strings and booleans, for example. So I thought it would be good to clarify and document whether the flavors are/should be really "everything" and "numbers and as little else as possible" or "everything" and "only built-in native JavaScript types," in which case the "number" one should perhaps really be thought of as the "builtin types" one, and presumably it would have bigint, string, boolean, Array, and Object support (a list that may not be exhaustive). Thoughts?
Beta Was this translation helpful? Give feedback.
All reactions