Update main.js

This commit is contained in:
Harvey Zack committed 2024-11-26 10:06:29 +08:00
1 parent 13d4fc9210
commit 57d6f25e5b
1 file changed
+8 -1
@@ -17,4 +17,11 @@
});
})();
(function () {
const language = window.navigator?.language || '';
const isDev = location.hostname === 'localhost';
if (!language.startsWith('zh') && !localStorage.getItem('lang-init') && !isDev) {
localStorage.setItem('lang-init', 'true');
window.location.href = 'https://artplayer.org/document/en/';
}
})();