Skip to content
New issue

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

Errors for non-Latin digits #8

Open
mohammadius opened this issue Sep 3, 2024 · 1 comment
Open

Errors for non-Latin digits #8

mohammadius opened this issue Sep 3, 2024 · 1 comment

Comments

@mohammadius
Copy link

mohammadius commented Sep 3, 2024

NumberFlow works with any locale that generates english numbers (like ja-JP or even ar-AE) but when using locales that generate non english number characters it causes an error (like fa-IR or ar-OM).
here's an example

@mohammadius mohammadius changed the title locales that generate non English characters cause error locales that generate non English number characters cause error Sep 3, 2024
@barvian barvian changed the title locales that generate non English number characters cause error Errors for non-Latin digits Jan 5, 2025
@barvian
Copy link
Owner

barvian commented Jan 5, 2025

This is definitely a limitation right now. As a workaround, you can add -u-nu-latn to a locale to force it to use Latin digits:

<NumberFlow locales="ar-OM-u-nu-latn" />

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants