I would like to convert Milliliter to liter (1000)
yesparthasarathy opened this issue ยท 4 comments
convert(1000).from('ml').to('l') , I am expecting output as 1.
Issue-Label Bot is automatically applying the label feature_request
to this issue, with a confidence of 0.95. Please mark this comment with ๐ or ๐ to give our bot feedback!
Links: app homepage, dashboard and code for this bot.
The example you provided works
import { convert } from 'convert';
console.log(convert(1000).from('ml').to('l'));
// 1
We also have unit tests confirming this behavior:
convert/test/conversions/volume.test.ts
Line 12 in 438bd1f
https://stackblitz.com/edit/angular-ivy-mgcm3z.
it still shows the wrong output.
Upgrade to version v1.1.4
, or a more recent release (v1.6.2
is the latest at the moment).
This was fixed in 8faa344.
I have deprecated the old versions with incorrect conversion ratios on npm.