国际化

This commit is contained in:
2025-09-12 13:13:29 +08:00
parent caef2ecc53
commit 2ebaeac1e9
18 changed files with 533 additions and 331 deletions

22
locale/index.js Normal file
View File

@@ -0,0 +1,22 @@
import en from './en.json'
import zhHans from './zh-Hans.json'
const messages = {
'en': en,
'zh-Hans': zhHans
}
let i18nConfig = {
silentTranslationWarn: true,
locale: uni.getLocale(),
messages
}
import Vue from 'vue'
import VueI18n from 'vue-i18n'
Vue.use(VueI18n)
const i18n = new VueI18n(i18nConfig)
export default i18n