openexchangerates / accounting.js

A lightweight JavaScript library for number, money and currency formatting - fully localisable, zero dependencies.
http://openexchangerates.github.io/accounting.js
MIT License
4.95k stars 528 forks source link

No "no rounding" option #137

Open ghost opened 8 years ago

ghost commented 8 years ago

Because I'm showing money to be sent, I don't want to round at all, rather just cut off the decimals except the first two. I want:

18357.982 => £18,357.98 18357.987 => £18,357.98 (I'm carrying over any leftover.)

I don't think this is the same as rounding down, as doesn't that only cover the case when it's 5, e.g. 18357.985?