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

Please use zh-HK to replace en-HK. #440

Closed
liuzhaowei55 opened this issue Oct 25, 2019 · 7 comments
Closed

Please use zh-HK to replace en-HK. #440

liuzhaowei55 opened this issue Oct 25, 2019 · 7 comments

Comments

@liuzhaowei55
Copy link

* Checks if the string is a mobile phone number (locale is one of ['zh-CN', 'zh-TW', 'en-ZA', 'en-AU', 'en-HK',

validatorjs/validator.js#622

@vlapo
Copy link
Contributor

vlapo commented Oct 26, 2019

What is a problem with en-HK?

@liuzhaowei55
Copy link
Author

What is a problem with en-HK?

zh-HK can alo work very well
https://github.com/validatorjs/validator.js/blob/b5a1d1f23fcdd24e3ca9d6090fdc0a06fcc23d55/src/lib/isMobilePhone.js#L94

en-HK is not supported in the locale
https://en.wikipedia.org/wiki/Locale_(computer_software)

政治正确 (Politically correct)

@vlapo
Copy link
Contributor

vlapo commented Oct 28, 2019

What is a problem with en-HK?

zh-HK can alo work very well
validatorjs/validator.js:src/lib/isMobilePhone.js@b5a1d1f#L94

Ok but it is not a problem.

en-HK is not supported in the locale
en.wikipedia.org/wiki/Locale_(computer_software)

Do not see any info about not supporting en-HK in locale strings

政治正确 (Politically correct)

Please do not bring politics into open-source.

I do not see any problem neither with en-HK or zh-HK as isMobilePhone accepts both of them.

@liuzhaowei55
Copy link
Author

@vlapo
I know en-HK still run very well, bug it no longer the standard.
https://en.wikipedia.org/wiki/Locale_(computer_software)
And it is easy to cause misunderstanding, this is just a comment, why not change it to a standard?

@vlapo
Copy link
Contributor

vlapo commented Oct 28, 2019

I have few reservations:

@liuzhaowei55
Copy link
Author

This will be my last reply.
I only found this area code definition: https://en.m.wikipedia.org/wiki/ISO_3166-2:CN
This thing is too boring.

@lock
Copy link

lock bot commented Nov 4, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Nov 4, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

2 participants