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

The PluralRules locale sr-Latn does not exist but is returned from intl-localeMatcher #3058

Closed
JakeChampion opened this issue Jul 20, 2021 · 1 comment
Labels

Comments

@JakeChampion
Copy link
Contributor

Which package?

Since this is a monorepo. Please specify which package this bug report is for.
This bug report is for packages:

  • @formatjs/intl-localematcher
  • @formatjs/intl-pluralrules

Describe the bug

When called the @formatjs/intl-localematcher package with sr-Latn-BA and the locales from @formatjs/intl-pluralrules/locale-data, it returns sr-Latn as the match but that locale does not exist

To Reproduce

Reproducible Steps/Repo

Steps to reproduce the behavior:

  1. Clone the GitHub Repository JakeChampion/intl-bug
  2. Run npm ci to install the same dependency versions I used
  3. Run npm start to execute the program
  4. You should see in the console:

The detected PluralRules Locale dependency for sr-Latn-BA is sr-Latn
Does the PluralRules locale dependency file exist? Answer: false

Expected behavior

The matched locale should be one which exists within @formatjs/intl-pluralrules/locale-data, most likely the locale sr.js

Desktop (please complete the following information):

  • OS: MacOS 10.15.7
@longlho
Copy link
Member

longlho commented Jul 20, 2021

Thanks for reporting! We'll take a look asap.

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

No branches or pull requests

2 participants