We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Intl.NumberFormat.prototype.formatRange()
@formatjs/intl-numberformat
When formatting currency ranges, the result differs from what browser returns and looks weird for people reading localized text.
const nf = new Intl.NumberFormat('es', { style: 'currency', currency: 'EUR', maximumFractionDigits: 0, }); console.log(nf.formatRange(10, 100)); // Chrome: 10-100 €. Polyfill: 10 €-100 €
Display the range as 10-100 € and also respect the other options passed in Intl.NumberFormat.
10-100 €
Intl.NumberFormat
Intl.NumberFormat.formatRange specification: https://tc39.es/ecma402/#sec-intl.numberformat.prototype.formatrange
Intl.NumberFormat.formatRange
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Which package?
@formatjs/intl-numberformat
Describe the bug
When formatting currency ranges, the result differs from what browser returns and looks weird for people reading localized text.
To Reproduce
Expected behavior
Display the range as
10-100 €
and also respect the other options passed inIntl.NumberFormat
.Desktop (please complete the following information):
Additional context
Intl.NumberFormat.formatRange
specification: https://tc39.es/ecma402/#sec-intl.numberformat.prototype.formatrangeThe text was updated successfully, but these errors were encountered: