Jint is a Javascript interpreter for .NET. It will convert JavaScript values to CLR objects like below. https://github.com/sebastienros/jint/blob/master/README.md
JINT converts JavaScript values to CLR objects
Object -> expando objects ( IDictionary and dynamic)
Array -> object[]
Date -> DateTime
number -> double
string -> string
boolean -> bool
Regex -> RegExp
Function -> Delegate
It seems that JavaScript in general only supports 64-point floating point numbers and no other number type. https://www.w3schools.com/js/js_numbers.asp That means there would likely be a need for some functions/libraries to ensure consistent handling for numbers that required fixed precisions during processing.
My questions is if JINT supports 128-bit floating point calculation. We have a need to keep numbers in System.Decimal. Let's say I pass in two decimals as parameters to calculate the sum or the product. Is there a way to do this in JINT without losing precisions?
If there is no support out-of-the-box from JINT, is there any work around?
Appreciate your answers!