Issue with not supported browser locale
See original GitHub issueIf I set my browser language to some unsupported datepicker language e.g. Italian it will throw an error:
`RangeError: Maximum call stack size exceeded
You can reproduce this bug even on demo page: https://vue-datepicker.netlify.app/, just set you browser language to some unsupported one. Here is screenshot of the error:
Also, workaround to set locale to :locale=“{lang: ‘en’}” does not work for me as then date picker does not show dates:
Any other way I can force default locale to en?
Issue Analytics
- State:
- Created 3 years ago
- Reactions:7
- Comments:6
Top Results From Across the Web
IT11799: WEB UI IS BROKEN WHEN BROWSER LOCALE IS ...
If you set your browser locale to any unsupported language, the web UI fails to render and there is only a blank page,...
Read more >The language you've chosen is not supported in this database.
Login Error – The language you've chosen is not supported in this database. You need to change your browser language to English (US)....
Read more >JavaScript for detecting browser language preference [duplicate]
I think the main problem here is that the browser settings don't actually affect the navigator.language property that is obtained via javascript.
Read more >Setting language preferences in a browser - W3C
Sometimes a server may determine which language to send to you in a way that doesn't rely on the Accept-Language information.
Read more >Navigator.language - Web APIs | MDN
language read-only property returns a string representing the preferred language of the user, usually the language of the browser UI. Value. A ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
In my case the workaround works if I regiser the component globally and pass { lang: ‘en’ } options
Solved this issue by downgrade to “0.2.4”