我从Angular 2.3.0
升级到Angular 4.3.0
,这打破了我的应用。这是我得到的错误。我得到几百TS1110
和TS1005
。我从所有角度模块中得到错误 - core
,compiler
,router
等。
node_modules/@angular/compiler/src/output/output_ast.d.ts(44,35): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(44,82): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(78,18): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(79,35): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(80,30): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(80,79): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(82,55): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(83,42): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(83,79): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(84,99): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(85,65): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(86,53): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(86,90): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(87,64): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(87,101): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(88,60): error TS1110: Type expected.
node_modules/@angular/compiler/src/output/output_ast.d.ts(89,63): error TS1110: Type expected.
node_modules/@angular/core/src/view/types.d.ts(431,14): error TS1005: '=' expected.
node_modules/@angular/core/src/view/types.d.ts(431,23): error TS1005: ';' expected.
node_modules/@angular/core/src/view/types.d.ts(432,14): error TS1005: '=' expected.
node_modules/@angular/core/src/view/types.d.ts(432,23): error TS1005: ';' expected.
我没有运气就提到了以下资源。
我甚至将typescript
升级为2.4.2
并尝试了各种排列和组合。
这是我的package.json
"dependencies": {
"@angular/common": "4.2.0",
"@angular/compiler": "4.2.0",
"@angular/core": "4.2.0",
"@angular/forms": "4.2.0",
"@angular/http": "4.2.0",
"@angular/platform-browser": "4.2.0",
"@angular/platform-browser-dynamic": "4.2.0",
"@angular/router": "4.2.0",
"@angular/upgrade": "4.2.0",
"@types/fs-extra": "^2.1.0",
"@types/glob": "^5.0.30",
"@types/jasmine": "2.5.38",
"@types/node": "^7.0.5",
"@types/ora": "^0.3.31",
"@types/rimraf": "^0.0.28",
"amqplib": "^0.5.1",
"body-parser": "~1.13.2",
"bunyan": "^1.8.10",
"compression": "^1.5.2",
"connect": "^3.4.0",
"connect-flash": "^0.1.1",
"cookie-parser": "^1.3.5",
"date-and-time": "^0.4.0",
"debug": "~2.2.0",
"ejs": "^2.3.4",
"es6-promise": "^3.0.2",
"es6-shim": "^0.33.3",
"express": "~4.13.1",
"express-cache-response-directive": "~1.0.0",
"express-session": "^1.11.3",
"fs": "0.0.2",
"groc": "^0.8.0",
"gulp": "^3.9.0",
"gulp-sourcemaps": "^1.6.0",
"gulp-typescript": "^2.10.0",
"gulp-webserver": "^0.9.1",
"highcharts-ng": "0.0.11",
"http": "0.0.0",
"jade": "~1.11.0",
"moment": "^2.18.1",
"mongojs": "^2.4.0",
"morgan": "^1.6.1",
"mysql": "^2.9.0",
"net": "^1.0.2",
"nodemon": "^1.7.1",
"passport": "^0.3.0",
"passport-google-oauth": "^0.2.0",
"path": "~0.12.7",
"q": "~1.4.1",
"reflect-metadata": "0.1.2",
"request": "^2.79.0",
"rxjs": "5.3.0",
"serve-favicon": "~2.3.0",
"serve-static": "^1.10.0",
"simple-text-parser": "~0.1.2",
"systemjs": "0.19.6",
"underscore": "^1.8.3",
"uuid": "^3.0.1",
"zone.js": "^0.8.4"
}
任何帮助将不胜感激!谢谢!