const toCurrency = (n, curr, LanguageFormat = undefined) => Intl.NumberFormat(LanguageFormat, { style: 'currency', currency: curr }).format(n);
toCurrency(100500, 'RUB', 'Ru-ru');
100 500,00 ₽
toCurrency(100500, 'CNY', 'zh-CN');
¥100,500.00
toCurrency(100500, 'BYN', 'be-BY');
100 500,00 BYN
toCurrency(100500, 'BYN', 'be-BY')
у меня возвращает строку "100 500,00 Br"
toCurrency(100500, 'BYN', 'ru-BY');