feat(I18n): Add Ii8n
feat(LocaleDropdown): Add LocaleDropdown Component feat(store): Add localeStore
This commit is contained in:
@@ -6,8 +6,9 @@ import WindiCSS from 'vite-plugin-windicss'
|
||||
import VueJsx from '@vitejs/plugin-vue-jsx'
|
||||
import EslintPlugin from 'vite-plugin-eslint'
|
||||
import VueI18n from '@intlify/vite-plugin-vue-i18n'
|
||||
import Icons from 'unplugin-icons/vite'
|
||||
import StyleImport, { ElementPlusResolve } from 'vite-plugin-style-import'
|
||||
import ViteSvgIcons from 'vite-plugin-svg-icons'
|
||||
import PurgeIcons from 'vite-plugin-purge-icons'
|
||||
|
||||
// https://vitejs.dev/config/
|
||||
const root = process.cwd()
|
||||
@@ -41,10 +42,6 @@ export default ({ command, mode }: ConfigEnv): UserConfig => {
|
||||
}
|
||||
}]
|
||||
}),
|
||||
Icons({
|
||||
compiler: 'vue3',
|
||||
autoInstall: true
|
||||
}),
|
||||
EslintPlugin({
|
||||
cache: false,
|
||||
include: ['src/**/*.vue', 'src/**/*.ts', 'src/**/*.tsx'] // 检查的文件
|
||||
@@ -53,7 +50,13 @@ export default ({ command, mode }: ConfigEnv): UserConfig => {
|
||||
runtimeOnly: true,
|
||||
compositionOnly: true,
|
||||
include: [resolve(__dirname, 'src/locales/**')]
|
||||
})
|
||||
}),
|
||||
ViteSvgIcons({
|
||||
iconDirs: [pathResolve('src/assets/svgs')],
|
||||
symbolId: 'icon-[dir]-[name]',
|
||||
svgoOptions: true
|
||||
}),
|
||||
PurgeIcons()
|
||||
],
|
||||
|
||||
css: {
|
||||
@@ -116,7 +119,8 @@ export default ({ command, mode }: ConfigEnv): UserConfig => {
|
||||
'vue-router',
|
||||
'vue-types',
|
||||
'element-plus/lib/locale/lang/zh-cn',
|
||||
'element-plus/lib/locale/lang/en'
|
||||
'element-plus/lib/locale/lang/en',
|
||||
'@iconify/iconify'
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user