我无法构建我的项目,因为有很多关于lib.es6.d.ts的错误
node_modules/typescript/lib/lib.es6.d.ts(20605,14):错误TS1005:';‘预期。

tsconfig.json
{
"compilerOptions": {
"target": "es6",
"module": "amd",
"moduleResolution": "node",
"removeComments": true,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"noEmitHelpers": false,
"sourceMap": true,
"noResolve": false,
"noEmitOnError": true,
"outDir": "dist/debug"
},
"filesGlob": [
"./**/*.ts",
"!./node_modules"
],
"exclude": [
"node_modules",
"jspm_packages",
"typings",
"dist",
"typings/*",
"typings/main.d.ts",
"typings/main",
"Scripts"
],
"compileOnSave": true,
"buildOnSave": true
}npm类型记录
+-- @angular/cli@6.2.9
| `-- @schematics/angular@0.8.9
| `-- typescript@2.9.2 deduped
+-- gulp-typedoc@1.2.1
| `-- typedoc@0.3.12
| `-- typescript@1.6.2
+-- gulp-typescript@2.14.1
| `-- typescript@1.8.10
+-- tslint@3.15.1 invalid: ">=5.0.0-dev" from node_modules/gulp-tslint
| `-- typescript@2.9.2 deduped
+-- typedoc@0.2.3
| `-- typescript@1.4.1
+-- typescript@2.9.2
`-- typings@1.5.0
`-- typings-core@1.6.1
`-- typescript@2.9.2 dedupedPS C:\WebProjects\COTT\COTT\OrderTemplateTool.Web>
发布于 2022-07-14 14:29:33
发布于 2022-07-07 15:34:24
我看你可能有一些角度不匹配的版本。你的标题是角版4.4.7。你的树上写着角-cli 6.2.9,而你的打字版本是2.7.2。对于角度和角度的要求是不同的。我会首先对齐这些版本,要么降低cli的级别,要么升级角度。然后擦除您的node_modules文件夹,并重新安装npm。用于角/角-cli升级这里的有用工具
https://stackoverflow.com/questions/72786178
复制相似问题