detectLocaleFromCookie helper
Clear and concise description of the problem
The Only default helper to resolve the locale is detectLocaleFromAcceptLanguageHeader. To get it from a cookie, one needs to write custom code.
Suggested solution
Implement a detectLocaleFromCookie helper
Alternative
Using custom function is already possible, but since there is a helper for accept-language already, more helpers make sense.
Additional context
No response
Validations
- [X] Follow our Code of Conduct
- [X] Read the Contributing Guide.
- [X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
I'd be happy to send a PR.
Thank you for your feedback!
You are right, it would be more convenient for us if there was a helper. However, in order to support this, it is necessary to support not only Cookies, but also Queries, and Paths.
see more ref: https://github.com/intlify/h3#%EF%B8%8F-utilites--helpers
Not sure if you want me to do it. If so, I will need #25 first.