<script>window.isoData = ${serialize(isoData)}</script>
<script>window.lemmyConfig = ${serialize(config)}</script>
+ <!-- A remote debugging utility for mobile
+ <script src="//cdn.jsdelivr.net/npm/eruda"></script>
+ <script>eruda.init();</script>
+ -->
+
${helmet.title.toString()}
${helmet.meta.toString()}
export function getBrowserLanguage(): string {
// Intersect lemmy's langs, with the browser langs
let langs = languages ? languages.map(l => l.code) : ["en"];
- let allowedLangs = navigator.languages.filter(v => langs.includes(v)) || [
- "en",
- ];
+
+ // NOTE, mobile browsers seem to be missing this list, so append en
+ let allowedLangs = navigator.languages
+ .concat("en")
+ .filter(v => langs.includes(v));
return allowedLangs[0];
}