-
Notifications
You must be signed in to change notification settings - Fork 67
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
Fallback locale does not fork #59
Comments
As documented in the types and the docs, |
I got you. But how to avoid the case when user's locale does not exists in the loadMessages? |
Yeah I think this is a valid enhancement, just need to figure out the implementation details. Looking into implementing a new config prop |
Released v4.4.0. Setting |
In case if we use locale that does not presented. For example:
And we use
GlobalizeProvider
withlocaleFallback: "en"
When user is in locale
sv
for example, we get the following error:The reason, that in the code we have:
react-native-globalize/src/globalize/index.ts
Line 49 in 3e3c63a
It means if cfg.fallback is "en", we still try to
findFallbackLocale
for localesv
which does not existWe need to change it to:
The text was updated successfully, but these errors were encountered: