-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
shouldPolyfill('fr')
returns incorrect value in intl-displaynames@6.6.2
#4267
Comments
can u provide a codesandbox? |
Sure thing: https://codesandbox.io/s/javascript-forked-h5d7yz?file=/src/index.js It seems like the issue comes from this particular call: import { shouldPolyfill } from "@formatjs/intl-displaynames/should-polyfill";
const foo = shouldPolyfill("fr"); With 6.6.1 I am getting Because of this bug my app is not loading |
Long story short, I had to replace: const foo = shouldPolyfill("fr");
await import(`@formatjs/intl-displaynames/locale-data/${foo}`); by: const foo = shouldPolyfill("fr");
await import(`@formatjs/intl-displaynames/locale-data/fr`); |
shouldPolyfill('fr')
returns incorrect value in intl-displaynames@6.6.2
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
As far as I know this issue is not resolved, and should not be closed. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
kk this issue is due to the list of |
For posterity, the problem is the list of supported locales have both |
Which package?
intl-displaynames
Describe the bug
After upgrading
intl-displaynames
from 6.6.1 to 6.6.2 I cannot use the library with localefr
. Same issue arises with 6.6.3 and above.To Reproduce
This works as expected:
However, this fails:
Error message:
The text was updated successfully, but these errors were encountered: