r/javascript • • Oct 02 '18

Money in JavaScript

https://timleland.com/money-in-javascript/
1 Upvotes

4 comments sorted by

View all comments

4

u/Rhyek Oct 02 '18

Just use decimal.js. It works great.

3

u/pilotInPyjamas Oct 02 '18

Is it just me, or wouldn't it be easier to just measure everything in cents and use integers? Nobody has $251 and then you don't need an additional library or learn a new api

-1

u/Rhyek Oct 02 '18

Probably just you! 🙂