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

Kosovo (XK), Netherlands Antilles (AN) LocaleCode.getCountryName() doesn't work right #16

Open
utschenik opened this issue Oct 19, 2020 · 4 comments

Comments

@utschenik
Copy link

Hello,

I have a custom country list, that i am looping through and trying to render the country list with it's orignal country names.
For 202 countries it works really great, but with 2 countries it doesn't work.

I am using the method LocaleCode.getCountryName() to get the original country names from Kosovo and Netherlands Antiles, but I get nothing returned.

Example:

LocaleCode.getCountryName('en-AN')
LocaleCode.getCountryName('en-XK')

Thanks for your help!

@meikidd
Copy link
Owner

meikidd commented Oct 19, 2020

Hi @utschenik , this module use iso-3166-1-alpha-2 under the hood to handle country names. I checked here https://github.com/georgzoeller/iso-3166-1-alpha-2/blob/master/index.js, and found out AN and XK are not included in it's country list. And they are not in Wiki ISO_3166-1_alpha-2 country list as well.

I would suggest you to raise an issue on iso-3166-1-alpha-2 project. Once they update it, I would like to release a new version accordingly.

@utschenik
Copy link
Author

i raised a new issue for both countries (georgzoeller/iso-3166-1-alpha-2#5), i would let you know in this issue if they adjusted their country list or not.

@utschenik
Copy link
Author

Hey merge is done with my changes (georgzoeller/iso-3166-1-alpha-2#6)

@meikidd
Copy link
Owner

meikidd commented Oct 19, 2020

That's great. But still need them to publish a new version to npm, so that I can upgrade my dependency version in package.json

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

No branches or pull requests

2 participants