Reputation: 8681
I am upgrading my angular 4 to angular 6 application. I am getting the following error while building my application.
error TS18003: No inputs were found in config file 'tsconfig.json'. Specified 'include' paths were '["../../node_modules/@wtw/**/*"]' and 'exclude' paths were '["**/*.sp
ec.ts","**/*.stub.ts","test/**/*.ts"]'.
Error: error TS18003: No inputs were found in config file 'tsconfig.json'. Specified 'include' paths were '["../../node_modules/@wtw/**/*"]' and 'exclude' paths were '["
**/*.spec.ts","**/*.stub.ts","test/**/*.ts"]'.
If I add "**/*" to the include I get the following error and the above error dissapears.
ERROR in e2e/app.e2e-spec.ts(3,1): error TS2304: Cannot find name 'describe'.
e2e/app.e2e-spec.ts(6,3): error TS2304: Cannot find name 'beforeEach'.
e2e/app.e2e-spec.ts(10,3): error TS2304: Cannot find name 'it'.
e2e/app.e2e-spec.ts(12,5): error TS2304: Cannot find name 'expect'.
tsconfig
{
"compileOnSave": false,
"compilerOptions": {
"outDir": "./dist/out-tsc",
"baseUrl": "src",
"sourceMap": true,
"declaration": false,
"moduleResolution": "node",
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"target": "es5",
"typeRoots": [
"node_modules/@types",
"type-definition"
],
"lib": [
"es2017",
"dom"
]
},
"include": [
"../node_modules/@wtw/**/*",
"**/*"
]
}
How do I resolve this issue.
Upvotes: 4
Views: 14323
Reputation: 181
Because the error says 'exclude' paths were '["/.spec.ts","/.stub.ts","test/**/*.ts"]', You need to have a *.ts file in the directory or sub directory, in which the tsconfig.app.json file resides with the include and exclude properties declared.
The "include" and "exclude" properties take a list of glob-like file patterns. The supported glob wildcards are:
If a segment of a glob pattern includes only * or .*, then only files with supported extensions are included (e.g. .ts, .tsx, and .d.ts by default with .js and .jsx if allowJs is set to true).
You can refer this for more help
Upvotes: 6