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

Can't add Haitian (ht) or Māori (mi) #445

Closed
aaronshaf opened this issue Jan 28, 2019 · 6 comments
Closed

Can't add Haitian (ht) or Māori (mi) #445

aaronshaf opened this issue Jan 28, 2019 · 6 comments
Labels

Comments

@aaronshaf
Copy link
Contributor

yarn run add-locale ht

Result:

Unknown locale: ht.
@aaronshaf
Copy link
Contributor Author

In locales.js:

  return (
    localeData !== null &&
    localeData !== undefined &&
    localeData.language in _makePlural2.default
  );

It looks like it's not finding ht in the make-plural library. Ideas?

@aaronshaf aaronshaf changed the title Can't add Haitian (ht) Can't add Haitian (ht) or Maori (mi) Jan 28, 2019
@aaronshaf aaronshaf changed the title Can't add Haitian (ht) or Maori (mi) Can't add Haitian (ht) or Māori (mi) Jan 28, 2019
@aaronshaf
Copy link
Contributor Author

Perhaps the make-plural function needs to be wrapped? Compare: https://github.com/messageformat/messageformat/blob/master/packages/messageformat/lib/plurals.js

@tricoder42
Copy link
Contributor

As described in make-plural eemeli/make-plural#11, CLDR is missing plural rules for Maori and Haitian. The wrapper would solve the problem as a temporary solution until these languages are added to CLDR.

Do you know what plural rules these languages use? If so, feel free to send a PR. I believe we could have just an object of locale data for each locale and if the locale code doesn't exists in CLDR, we would pull own config.

@aaronshaf
Copy link
Contributor Author

It'd be nice to have a fallback for these situations that doesn't break the whole build (especially in scenarios where we support dozens of other languages).

@makenosound
Copy link

I’ve bumped into this same issue today too (also for Maori) and it would definitely be nice to have a mechanism for specifying additional custom locales.

@stale
Copy link

stale bot commented Oct 29, 2020

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.

@stale stale bot added the wontfix label Oct 29, 2020
@stale stale bot closed this as completed Nov 5, 2020
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

3 participants