During my attempt to compile my typescript source code, I've noticed that the compiler is also attempting to compile the types found within my node_modules directory. I am currently utilizing typescript version 2.6.1 and have my tsconfig file set up as follows
{
"compilerOptions": {
"allowSyntheticDefaultImports": true,
"outDir": "./dist",
"mapRoot": "./dist",
"module": "commonjs",
"target": "es6",
"sourceMap": true,
"sourceRoot": "./source",
"removeComments": false
},
"exclude": [
"node_modules",
"test"
],
"include": [
"source/*.ts"
]
}
Upon executing the command "tsc -w -p tsconfig.json," I encountered the following error:
node_modules/@types/es6-promise/index.d.ts(11,15): error TS2300: Duplicate identifier 'Promise'.