mathjs 12.4.2 → 12.4.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (42) hide show
  1. package/HISTORY.md +8 -0
  2. package/README.md +4 -0
  3. package/bin/cli.js +1 -1
  4. package/lib/browser/math.js +1 -1
  5. package/lib/browser/math.js.LICENSE.txt +2 -2
  6. package/lib/browser/math.js.map +1 -1
  7. package/lib/cjs/core/function/config.js +1 -11
  8. package/lib/cjs/core/function/import.js +3 -4
  9. package/lib/cjs/expression/parse.js +7 -7
  10. package/lib/cjs/function/algebra/derivative.js +1 -1
  11. package/lib/cjs/function/algebra/rationalize.js +2 -2
  12. package/lib/cjs/function/algebra/simplifyConstant.js +1 -1
  13. package/lib/cjs/function/statistics/mad.js +1 -1
  14. package/lib/cjs/function/statistics/std.js +1 -1
  15. package/lib/cjs/function/statistics/utils/improveErrorMessage.js +2 -2
  16. package/lib/cjs/header.js +2 -2
  17. package/lib/cjs/type/unit/Unit.js +3 -2
  18. package/lib/cjs/utils/array.js +0 -11
  19. package/lib/cjs/utils/bignumber/formatter.js +1 -1
  20. package/lib/cjs/utils/factory.js +1 -2
  21. package/lib/cjs/utils/object.js +1 -1
  22. package/lib/cjs/utils/snapshot.js +4 -4
  23. package/lib/cjs/version.js +1 -1
  24. package/lib/esm/core/function/config.js +1 -11
  25. package/lib/esm/core/function/import.js +3 -4
  26. package/lib/esm/expression/parse.js +7 -7
  27. package/lib/esm/function/algebra/derivative.js +1 -1
  28. package/lib/esm/function/algebra/rationalize.js +2 -2
  29. package/lib/esm/function/algebra/simplifyConstant.js +1 -1
  30. package/lib/esm/function/statistics/mad.js +1 -1
  31. package/lib/esm/function/statistics/std.js +1 -1
  32. package/lib/esm/function/statistics/utils/improveErrorMessage.js +2 -2
  33. package/lib/esm/type/unit/Unit.js +3 -2
  34. package/lib/esm/utils/array.js +0 -10
  35. package/lib/esm/utils/bignumber/formatter.js +1 -1
  36. package/lib/esm/utils/factory.js +1 -2
  37. package/lib/esm/utils/object.js +1 -1
  38. package/lib/esm/utils/snapshot.js +4 -4
  39. package/lib/esm/version.js +1 -1
  40. package/package.json +1 -1
  41. package/types/EXPLANATION.md +13 -1
  42. package/types/index.d.ts +14 -1
package/HISTORY.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # History
2
2
 
3
+ # 2024-05-31, 12.4.3
4
+
5
+ - Fix: serialization of Units without a value, see #1240.
6
+ - Fix: outdated, incorrect documentation about the order of precedence for
7
+ operator modulus `%`. See #3189.
8
+ - Fix: #3197 improve `quantileSeq` type definitions (#3198). Thanks @domdomegg.
9
+
10
+
3
11
  # 2024-04-24, 12.4.2
4
12
 
5
13
  - Fix #3192: function `isNaN` returns `false` for `NaN` units in a matrix or
package/README.md CHANGED
@@ -160,6 +160,10 @@ Then, the tests can be executed:
160
160
 
161
161
  npm test
162
162
 
163
+ To test the type definitions:
164
+
165
+ npm run test:types
166
+
163
167
  Additionally, the tests can be run on FireFox using [headless mode](https://developer.mozilla.org/en-US/Firefox/Headless_mode):
164
168
 
165
169
  npm run test:browser
package/bin/cli.js CHANGED
@@ -113,7 +113,7 @@ function completer (text) {
113
113
  const ignore = ['expr', 'type']
114
114
  for (const func in math.expression.mathWithTransform) {
115
115
  if (hasOwnProperty(math.expression.mathWithTransform, func)) {
116
- if (func.indexOf(keyword) === 0 && ignore.indexOf(func) === -1) {
116
+ if (func.indexOf(keyword) === 0 && !ignore.includes(func)) {
117
117
  matches.push(func)
118
118
  }
119
119
  }