Jason

Results 103 comments of Jason

This isn't a floating point issue and is currently working as intended. `12345.67 / 10` is `1234.567`. currency.js has to decide how to handle rounding in instances in which there...

This one is a bit tricky, the `intValue` is used internally to keep track of the "true" value, the `increment` property only sets the the value when its converted to...

It looks like `format` only takes into account the precision of the original currency object. The only specific reason is generally currencies would keep the same precision for input/output. Is...

It seems reasonable to allow `currency.format()` to accept similar options as the original currency function. I think `precision` is the only property that isn't accounted for, and there's been several...

One of the key features of currency.js is in how it accepts various inputs. `a1b2c3` is probably not the best example of a test, but it's more so that the...

Unfortunately, it's not universal that a symbol is used for currency symbols. Several countries use `kr` as their symbol for _krona_ or _krone_, while you might see `USD $1` or...

@ericvera I think a having `strictInput` or `strict` mode actually sounds reasonable. I need to think about what that means in relation to `errorOnInvalid` but that's something that could potentially...

You could use a [custom formatter](https://currency.js.org/#format-default-null): ```js const formatter = (currency, settings) => { if (!currency.cents()) { return currency.value; } return currency.value.toFixed(settings.precision); }; const c = value => currency(value, {...

Yes, feel free to add a PR!

This is expected behavior. ```js currency(1, { fromCents: true }) // => $0.01 currency(123, { fromCents: true }) // => $1.23 currency(123, { fromCents: true, precision: 3 }) // =>...