-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Supporting Internationalized Resource Identifier (RFC 3987) #1164
Comments
There's little chance that a new dependency will be added, since Joi is itself a dependency of hapi and those downstream deps are verrrry closely guarded. That being said, that's not the only option for adding internationalization validation. If @Marsup gives the broad goal of supporting international characters in uri validation, I'll put this on my radar, right behind isemail; anyone else who wants to take a stab though has my full support! I am happy to help where I can. |
Hm, actually, I think the decision whether or not to include IRIs by default in the validation comes down to the intended function of From RFC 3987 section 1.2.a -
So, if |
I think they mean it should be normalized to punycode internally. But for the facing user https://www.examplé.com is still a valid domain, right? Maybe we should talk about adding |
Admittedly I didn't have the chance to finish reading the RFC yet... :P |
@Xrampino This is where things become interesting because there's a number of different RFCs which apply to this. From what I've dug through you are correct that there are some specifications out there which do indeed support non-ASCII characters within the user's browser. These are then converted from Unicode to ASCII. I agree with you that I don't think we should be modifying |
There hasn't been any demand for that in the past few years, nobody volunteered to implement it, and I don't see any joi extension doing it. Shall I close ? |
This thread has been automatically locked due to inactivity. Please open a new issue for related bugs or questions following the new issue template instructions. |
URL validation right now fails with the widely-supported IRI (RFC-3987), for example
https://www.example.com/michaël
.This library seems to support it, could it be possible to switch to this one for URL validation internally ? https://github.com/garycourt/uri-js
The text was updated successfully, but these errors were encountered: