diff --git a/packages/shared/package.json b/packages/shared/package.json index bad489a..0f3905f 100644 --- a/packages/shared/package.json +++ b/packages/shared/package.json @@ -1,6 +1,6 @@ { "name": "vite-plugin-shared", - "version": "1.0.7", + "version": "1.0.8", "description": "一款针对assets目录规范,自动生成出口shared.ts的工具", "author": "Gauhar Chan", "files": [ diff --git a/packages/shared/src/shared.ts b/packages/shared/src/shared.ts index 3a5849e..e55af96 100644 --- a/packages/shared/src/shared.ts +++ b/packages/shared/src/shared.ts @@ -52,7 +52,7 @@ export function createShared(targetPath: string) { // 遍历获取所有ts文件 const allTs = recursion( targetPath, - assetsModules.filter((file) => !file.endsWith('.ts') || !file.endsWith('.tsx')) // 剔除shared.ts + assetsModules.filter((file) => !file.endsWith('.ts')) // 剔除shared.ts ); if (allTs.size) { // 写入代码内容