Skip to content

Commit 55b477a

Browse files
committed
unplugin-auto-import:排除自动导入店铺装修组件
1 parent 6160c2f commit 55b477a

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

build/vite/index.ts

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -60,18 +60,11 @@ export function createVitePlugins() {
6060
}
6161
}),
6262
Components({
63-
// 要搜索组件的目录的相对路径
64-
dirs: ['src/components'],
65-
// 组件的有效文件扩展名
66-
extensions: ['vue', 'md'],
67-
// 搜索子目录
68-
deep: true,
69-
include: [/\.vue$/, /\.vue\?vue/],
7063
// 生成自定义 `auto-components.d.ts` 全局声明
7164
dts: 'src/types/auto-components.d.ts',
7265
// 自定义组件的解析器
7366
resolvers: [ElementPlusResolver()],
74-
exclude: [/[\\/]node_modules[\\/]/]
67+
globs: ["src/components/**/**.{vue, md}", '!src/components/DiyEditor/components/mobile/**']
7568
}),
7669
EslintPlugin({
7770
cache: false,

0 commit comments

Comments
 (0)