Y
Hacker News
new
|
ask
|
show
|
jobs
by
RedShift1
634 days ago
That seems super dumb indeed. I really wish JSON had an actual decimal type, we already have valid "e" notation (like 10e2), why not have a "d" notation, like 5d3 (meaning 5.3) or 5.3d.
2 comments
wiktor-k
634 days ago
Yes! Something similar to
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
link
svapnil
634 days ago
All amounts in this library are in base units (whole numbers) and no arithmetic is used!
For financial calculations I recommend using Dinero.js
link
RedShift1
634 days ago
So 1 euro is written as 100?
link