andrewcarreiro / vscode-calculate

Calculation extension for Visual Studio Code
Do What The F*ck You Want To Public License
13 stars 10 forks source link

Math.js unit conversion example result in NaN #9

Open sandos opened 5 years ago

sandos commented 5 years ago

One of the Math.js samples is "12.7 cm to inch", but here in results in:

12.7 cm to inch=NaN

It does not seem to matter what unit I enter, either:

12.7 cm to in=NaN

or even

12.7 cm to mm=NaN

Some other samples work fine, such as sin(45 deg) ^ 2=0.5.

navossoc commented 3 years ago

Hi there...

Since this extension seems unmaintained, I forked and created an updated version. It's almost the same code, just a few tweaks.

Since I'm using a new version of math.js, it support unit conversions.

Feel free to check it here: https://marketplace.visualstudio.com/items?itemName=navossoc.calculate2