feat: i18n locale auto-detect (issue #153)#152
Conversation
|
There are a couple of problems here:
Can you address these problems? |
|
I just happened to notice this and figured I'd also respond. To respond directly to you @IlCallo, yeah. It does return a DOMString/String. Not sure why we're creating a string again, maybe a precaution for that off chance you get a weird locale back that's not valid, but then it would use The code should probably be: However, here's something else. If we wanted to support auto-detection of the locale through navigator, couldn't we opt for possibly something like this? Languages will return an array of preferred languages if I can recall correctly and the |
This PR makes the app auto-detect browser locale and set it.
What kind of change does this PR introduce? (check at least one)
Does this PR introduce a breaking change? (check one)
The local selection behavior would change. It will now select the locale from the browser, instead of from the hard-coded default.