xuexiaole-mobile/index.html
2025-08-05 19:20:06 +08:00

44 lines
1.4 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!doctype html>
<html>
<head>
<meta charset="UTF-8" />
<script>
var coverSupport =
'CSS' in window &&
typeof CSS.supports === 'function' &&
(CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
document.write(
'<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' +
(coverSupport ? ', viewport-fit=cover' : '') +
'" />',
)
</script>
<script>
// 只在开发环境加载vConsole
// 判断是否为开发环境本地开发或包含debug参数
var isDev = window.location.hostname === 'test.xuexiaole.com'
if (isDev) {
// 动态加载vConsole脚本
var script = document.createElement('script')
script.src = 'https://cdn.bootcdn.net/ajax/libs/vConsole/3.3.4/vconsole.min.js'
script.onload = function () {
// 脚本加载完成后初始化vConsole
var vConsole = new VConsole()
console.log('vConsole已在开发环境中启用')
}
script.onerror = function () {
console.warn('vConsole加载失败')
}
document.head.appendChild(script)
}
</script>
<title></title>
<!--preload-links-->
<!--app-context-->
</head>
<body>
<div id="app"><!--app-html--></div>
<script type="module" src="/src/main.ts"></script>
</body>
</html>