to-centesimal
This is a little module that tries to convert units of currency (think dollars) into centesimal values.
Install
$ npm install to-centesimal
Usage
var cents = 150 125 100 1050 1 1
Page weight
compression | size |
---|---|
to-centesimal.js | 2.36 kB |
to-centesimal.min.js | 1.66 kB |
to-centesimal.min.js.gz | 864 B |
Caveats
The regular expression used is auto-generated from a list of countries’ currency symbols. I’m too lazy to research all of them, so please open an issue if notice something is amiss.