Intl.js
Intl.js copied to clipboard
Outdated currency formatting for de-AT locale
In Chrome the following code snippet …
(new Intl.NumberFormat('de-AT', {
style: 'currency',
currency: 'EUR',
minimumFractionDigits: 0,
maximumFractionDigits: 2
})).format(12000.12)
… prints "€ 12.000,12" – which is exactly as expected.
However when I run …
var IntlPolyfill = require('intl');
Intl.NumberFormat = IntlPolyfill.NumberFormat;
Intl.DateTimeFormat = IntlPolyfill.DateTimeFormat;
(new Intl.NumberFormat('de-AT', {
style: 'currency',
currency: 'EUR',
minimumFractionDigits: 0,
maximumFractionDigits: 2
})).format(12000.12)
… in RunKit with node.js v8.6.0 it prints "€ 12 000,12".
Note that there was recently an update to the CLDR in regards to this aspect.
can confirm it for chrome browser
// my locale is de-AT
(new IntlPolyfill.NumberFormat()).format(1000);
"1 000"
(new Intl.NumberFormat()).format(1000);
"1,000" // correct
Any update on this?