Open wendt88 opened 4 years ago
I second that. I have the same issue. The weird thing is that for some reason the locale affects the currency (which isn't supposed to be like that). My example:
(new Intl.NumberFormat('bg-BG', { style: 'currency', currency: 'BGN' })).format(1)
// returns "1.00 лв." which is correct
(new Intl.NumberFormat('en-US', { style: 'currency', currency: 'BGN' })).format(1)
// returns "$1.00" which is incorrect - it should return "BGN 1.00"
In both cases the currency is the same (BGN) but the printed currency symbol is different.
Here, I've made a JSFiddle example so you can see the results from the same example but in vanilla JS environment
UPDATE: I tested this on iOS and it seems to work correctly which means that the issue is probably specific to Android.
This pull request seems to fix the issue for me
more than 6 months are passed and no one was able to merge this awesome bug fixing PR :see_no_evil:
more than 6 months are passed and no one was able to merge this awesome bug fixing PR 🙈
I still use a local version with that fix because of that
returns:
$ 1.00
it seems that the currency option gets ignored... it takes always the currency from thelocale
'slocation