rmariuzzo/Lang.js

HTML lang attribute to auto-setLocale

Closed this issue · 2 comments

Why to manually enforce the default locale:

Example:
<script type="text/javascript"> Lang.setLocale('{{App::getLocale()}}'); </script>

While everyone has the locale defined as an html attribute: lang?

Example:
<html lang="el">

It would be great to automatically check the lang attribute of the html tag to preset the default locale.

Correct