docs: 完善注释

Former-commit-id: 1137c14917d7f2425ec7abbca80b4771c4a1ea2b
This commit is contained in:
haoxr
2023-02-21 00:38:13 +08:00
parent 9653cf9939
commit 950460d4c9

View File

@@ -58,7 +58,7 @@ export default defineConfig(({ mode }: ConfigEnv): UserConfig => {
// 自动导入 Vue 相关函数ref, reactive, toRef 等 // 自动导入 Vue 相关函数ref, reactive, toRef 等
imports: ['vue', '@vueuse/core'], imports: ['vue', '@vueuse/core'],
eslintrc: { eslintrc: {
enabled: false, // 没有此json文件开启生成后关闭避免重复生成 enabled: false, // 改为true用于生成eslint配置,生成后改回false避免重复生成消耗
filepath: './.eslintrc-auto-import.json', filepath: './.eslintrc-auto-import.json',
globalsPropValue: true globalsPropValue: true
}, },
@@ -73,20 +73,19 @@ export default defineConfig(({ mode }: ConfigEnv): UserConfig => {
// 是否在vue模板中自动导入 // 是否在vue模板中自动导入
vueTemplate: true, vueTemplate: true,
dts: path.resolve(pathSrc, 'types', 'auto-imports.d.ts') dts: path.resolve(pathSrc, 'types', 'auto-imports.d.ts') // 配置文件生成位置,默认是根目录 /auto-imports.d.ts
}), }),
Components({ Components({
resolvers: [ resolvers: [
// 自动注册图标组件 // 自动注册图标组件
IconsResolver({ IconsResolver({
// element-plus图标库其他图标库 https://icon-sets.iconify.design/ enabledCollections: ['ep'] //@iconify-json/ep 是 Element Plus 的图标库
enabledCollections: ['ep']
}), }),
// 自动导入 Element Plus 组件 // 自动导入 Element Plus 组件
ElementPlusResolver() ElementPlusResolver()
], ],
dts: path.resolve(pathSrc, 'types', 'components.d.ts') dts: path.resolve(pathSrc, 'types', 'components.d.ts') // 配置文件生成位置,默认是根目录 /components.d.ts
}), }),
Icons({ Icons({