我的混合angularjs/angular6
应用程序出现编译错误。
它发生在~\node_modules\@angular\upgrade\static\src\common\angular1.d.ts
文件中。
属性“$inject”的类型不兼容。类型“ReadonlyArray”不可分配给类型“string[]”。“ReadonlyArray”类型中缺少属性“pop”。>~\node_modules\@angular\upgrade\static\src\common\angular1.d.ts 10 活动
angularjs 应用程序是在 VS2017 中创建的扩展应用程序。我不完全确定解决此问题可能需要哪些其他信息,但我会尽力提供。
编辑:这是所要求的 package.json:
{
"name": "amx",
"version": "0.0.1",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "6.1.9",
"@angular/common": "6.1.9",
"@angular/compiler": "6.1.9",
"@angular/core": "6.1.9",
"@angular/forms": "6.1.9",
"@angular/http": "6.1.9",
"@angular/platform-browser": "6.1.9",
"@angular/platform-browser-dynamic": "6.1.9",
"@angular/upgrade": "6.1.9",
"@angular/router": "6.1.9",
"core-js": "^2.5.4",
"rxjs": "~6.3.3",
"zone.js": "~0.8.26"
},
"devDependencies": {
"@angular-devkit/build-angular": "~0.9.0-rc.1",
"@angular/cli": "~7.0.0-rc.1",
"@angular/compiler-cli": "6.1.9",
"@angular/language-service": "6.1.9",
"@types/jasmine": "~2.8.8",
"@types/jasminewd2": "~2.0.3",
"@types/node": "~8.9.4",
"codelyzer": "~4.3.0",
"jasmine-core": "~2.99.1",
"jasmine-spec-reporter": "~4.2.1",
"karma": "~3.0.0",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage-istanbul-reporter": "~2.0.1",
"karma-jasmine": "~1.1.2",
"karma-jasmine-html-reporter": "^0.2.2",
"protractor": "~5.4.0",
"ts-node": "~7.0.0",
"tslint": "~5.11.0",
"typescript": "^2.9.2"
}
}