我使用的是 VisualStudio 代码,并且有一个相当常见的项目结构:
├── client/
│ ├── tsconfig.json
├── shared/
├── server/
│ ├── tsconfig.json
├── project.json
这两个 tsconfig 文件有不同的设置(例如,client/
下的一个目标是 ES5,server/
下的一个目标是 ES6)。注意,根目录中没有 tsconfig。
问题是,我希望两个项目都包含共享目录。我不能使用 tsconfig,因为 exclude
选项不允许我包含比 tsconfig.json 目录更高的文件夹,而使用 files
我必须不断更新文件列表,因为它不支持 globs。
注意,我可以通过将共享文件夹添加到 tsc 来编译,我想要的是 Visual Studio Code IDE 能够识别智能感知的共享代码等。
是等待 FilesGlob的唯一选择吗?