So, the math module links to the following page for how to format expressions: math.js | an extensive math library for JavaScript and Node.js
So, on that page, they have very simple examples for how to convert numbers to a hexadecimal equivalent:
format(255, {notation: "hex"})
But when I try that, I get an error:
DataError
Unknown notation "hex". Choose "auto", "exponential", or "fixed".
But auto, exponential, or fixed are not what I need. I need to be able to use the hex notation, which is in the math.js documentation. Does anyone know how to convert a regular decimal number to it’s hexadecimal equivalent?
Thanks