Jos de Jong
fc5c202e53
Merge branch 'typescript_improvements' of https://github.com/LearnSomethingTeam/mathjs into LearnSomethingTeam-typescript_improvements
2021-10-02 09:41:33 +02:00
Jos de Jong
ed0fe9678e
Fix #2319 : make the API of Parser.evaluate consistent with math.evaluate: support a list with expressions as input
2021-09-20 21:42:36 +02:00
Josh Hansen
8317eb5545
Re-fix the isConditionalNode typo that was corrected in 9.4.5
2021-09-17 01:54:32 -07:00
Josh Hansen
d01d9ea101
Redefine MathNode as a union type of interfaces implementing MathNodeCommon
2021-09-17 01:48:11 -07:00
Josh Hansen
402fa0e362
Array<SimplifyRule> -> SimplifyRule[]
2021-09-17 01:46:33 -07:00
Josh Hansen
8a80ed83a4
Add ConstantNode as an alias for MathNode and return it
2021-09-17 01:46:27 -07:00
Josh Hansen
0a9881e3cf
Make AssignmentNode extend MathNode
2021-09-17 01:46:22 -07:00
Josh Hansen
386f21efbd
Various improvements to the Typescript typings
...
Allows instantiation of classes (e.g. new ConstantNode(5))
Corrects the default invocation of `rationalize` (the signatures were in
the wrong order---MathNode is now the default return type)
Makes `create` return a `MathJsStatic` rather than
`Partial<MathJsStatic>` which is painful to use and largely unnecessary
because most fields on MathJsStatic are already optional.
Adds convenient aliases for `subtract`
Adds `implicit?: boolean` to MathNode
Make the unit on Unit.toNumber and Unit.toNumeric optional like it is in practice
Represent math.simplify.rules and math.simplify.simplifyCore
2021-09-17 01:46:16 -07:00
Wim Devos
d3c63677d0
Update SetCartesian documentation ( #2310 )
...
* Update SetCartesian documentation
* Remove trailing spaces
Co-authored-by: Jos de Jong <wjosdejong@gmail.com>
2021-09-15 22:08:43 +02:00
Michal Grňo
37cc651df2
Fix typo in isConditionalNode in types/index.d.ts ( #2307 )
...
`isConditionalnode` → `isConditionalNode`
Co-authored-by: Jos de Jong <wjosdejong@gmail.com>
2021-09-15 09:52:38 +02:00
Michal Grňo
64909e7fc2
add isRelationalNode to MathNode in types/index.d.ts ( #2308 )
...
Co-authored-by: Jos de Jong <wjosdejong@gmail.com>
2021-09-15 09:42:29 +02:00
Kiran Chand
34e461aec4
Adding type definition for hasNumericValue ( #2281 )
...
* adding hasNumericValue to types
* adding hasNumericValue to types
Co-authored-by: write2kcl <write2kcltech@alamy.com>
2021-09-15 09:29:05 +02:00
Kiran Chand
0850ac2ca6
Fixing incorrect typing error for floor function. ( #2246 )
...
* fixing incorrect typing error for floor function
* removing prettier auto format
Co-authored-by: write2kcl <write2kcltech@alamy.com>
Co-authored-by: Jos de Jong <wjosdejong@gmail.com>
2021-06-23 10:45:16 +02:00
Manuel Serra
6e2abc90ec
Fix outdated types ( #2252 )
...
Co-authored-by: Jos de Jong <wjosdejong@gmail.com>
2021-06-23 10:43:50 +02:00
Opportunity
7fea45d4a3
Add types for custom parsing functions ( #2228 )
...
* Add types for custom parsing functions
See https://github.com/DefinitelyTyped/DefinitelyTyped/pull/52648
* Update index.ts
Co-authored-by: Jos de Jong <wjosdejong@gmail.com>
2021-06-05 11:42:55 +02:00
andrebianchessi
abdd258ac2
Adds types for eigs function ( #2216 )
...
* Adds types for eigs. fixes #2100
* adds space
* BigNumber[] fix
2021-05-19 16:25:13 +02:00
Jos de Jong
477906d65a
Fix #2123 : add type definitions for functions row and column
2021-05-09 15:31:03 +02:00
Jos de Jong
40f515f9a1
Fix #2185 : Fix TypeScript definition of unit division, which can also return a number
2021-05-09 15:29:12 +02:00
Jos de Jong
14c730ba53
Fix #2019 : Remove null from the TypeScript definitions
2021-05-09 15:26:52 +02:00
Meow
2b402f7cc3
Add type declaration of DefinitelyTyped ( #2192 )
...
Co-authored-by: Jos de Jong <wjosdejong@gmail.com>
2021-05-09 15:20:27 +02:00