更新到 angular 9 后,我收到警告:
\src\main.ngtypecheck.ts is part of the TypeScript compilation but it's unused.
Add only entry points to the 'files' or 'include' properties in your tsconfig.
\src\polyfills.ngtypecheck.ts is part of the TypeScript compilation but it's unused.
Add only entry points to the 'files' or 'include' properties in your tsconfig.
Run Code Online (Sandbox Code Playgroud)
我的 tsconfig.app.json:
{
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/app",
"types": []
},
"files": ["main.ts", "polyfills.ts"],
"exclude": [
"test.ts",
"**/*.spec.ts"
]
}
Run Code Online (Sandbox Code Playgroud)
如何解决这些警告?
@Felix 如果您使用的是@angular-builders/custom-webpack 包,则会由于@ngtools/webpack v9 依赖项而导致警告
| 归档时间: |
|
| 查看次数: |
4578 次 |
| 最近记录: |