diff --git a/app/constants/index.ts b/app/constants/index.js similarity index 100% rename from app/constants/index.ts rename to app/constants/index.js diff --git a/app/plugins/http.ts b/app/plugins/http.js similarity index 100% rename from app/plugins/http.ts rename to app/plugins/http.js diff --git a/app/plugins/i18n.ts b/app/plugins/i18n.js similarity index 85% rename from app/plugins/i18n.ts rename to app/plugins/i18n.js index ad5fb7c..127eda7 100644 --- a/app/plugins/i18n.ts +++ b/app/plugins/i18n.js @@ -1,4 +1,4 @@ -import type { Locale as TypeLocale } from '#i18n' + import { Locale } from 'vant' import enUS from 'vant/es/locale/lang/en-US' import zhCN from 'vant/es/locale/lang/zh-CN' @@ -6,7 +6,7 @@ import jaJP from 'vant/es/locale/lang/ja-JP' import zhTW from 'vant/es/locale/lang/zh-TW' export default defineNuxtPlugin(() => { - // 载入 vant 语言包 + Locale.use('zh-CN', zhCN) Locale.use('en-US', enUS) Locale.use('ja-JP', jaJP) @@ -15,11 +15,9 @@ export default defineNuxtPlugin(() => { if (import.meta.client) { const i18n = useNuxtApp().$i18n const { setLocale } = i18n - const lang = localStorage.getItem('lang') - if (lang) { - setLocale(lang as TypeLocale) + setLocale(lang) Locale.use(lang) } else { diff --git a/app/plugins/vconsole.client.ts b/app/plugins/vconsole.client.js similarity index 100% rename from app/plugins/vconsole.client.ts rename to app/plugins/vconsole.client.js diff --git a/app/static/styles/global.css b/app/static/styles/global.css deleted file mode 100644 index e69de29..0000000 diff --git a/app/static/styles/vars.css b/app/static/styles/vars.css deleted file mode 100644 index e69de29..0000000