I am encountering an issue with a module within the node_modules directory while compiling my Angular 4 project. The error messages I'm receiving are as follows, even after attempting to exclude the problematic module in the tsconfig.json file. Can anyone assist me in resolving this?
ERROR in D:/workspace/demo/node_modules/@types/d3-collection/index.d.ts (148,23): ',' expected.
ERROR in D:/workspace/demo/node_modules/@types/d3-collection/index.d.ts (483,40): ',' expected.
ERROR in D:/workspace/demo/node_modules/@types/d3-collection/index.d.ts (148,25): Type parameter name cannot be 'any'
Despite excluding the node_modules folder to prevent these errors, I am still encountering the same issue when running npm start
.
tsconfig.json
{
"compilerOptions": {
"declaration": false,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"lib": [
"es6",
"dom"
],
"mapRoot": "./",
"module": "es6",
"moduleResolution": "node",
"outDir": "../dist/out-tsc",
"sourceMap": true,
"target": "es5",
"typeRoots": [
"../node_modules/@types"
]
},
"exclude": [
"**/node_modules/*"
]
}