我如何知道每个Ionic版本支持哪种角度版本?我经常遇到错误“没有导出的成员”,例如:
模块
".../node_modules/@angular/core/index"
没有导出的成员InjectionToken
。模块
".../node_modules/@angular/core/index"
没有导出 成员ComponentResolver
。
然后我谷歌它通常,论坛建议更新版本。我这样做但后来又出现了另一个不兼容的版本错误。
这是我的package.json
"dependencies": {
"@angular/common": "2.2.1",
"@angular/compiler": "2.2.1",
"@angular/compiler-cli": "2.2.1",
"@angular/core": "2.2.1",
"@angular/forms": "2.2.1",
"@angular/http": "2.2.1",
"@angular/platform-browser": "2.2.1",
"@angular/platform-browser-dynamic": "2.2.1",
"@angular/platform-server": "2.2.1",
"@ionic-native/core": "3.1.0-rc.6",
"@ionic-native/geolocation": "^4.5.3",
"@ionic-native/google-maps": "^4.5.3",
"@ionic-native/network": "^4.5.3",
"@ionic-native/splash-screen": "4.3.2",
"@ionic-native/sqlite": "^4.5.3",
"@ionic-native/sqlite-porter": "^4.5.3",
"@ionic-native/status-bar": "4.3.2",
"@ionic/storage": "2.1.3",
"angularfire2": "^2.0.0-beta.2",
"firebase": "^3.2.1",
"ionic-angular": "2.0.0-beta.11",
"ionic-native": "2.4.1",
"ionic-plugin-keyboard": "~2.2.1",
"ionicons": "3.0.0",
"moment": "^2.20.1",
"ng2-cordova-oauth": "0.0.6",
"rxjs": "5.5.2",
"statex": "^1.1.3",
"sw-toolbox": "3.4.0",
"typescript": "^2.7.2",
"uk.co.workingedge.cordova.plugin.sqliteporter": "^1.0.2",
"zone.js": "0.8.18"
},
"devDependencies": {
"@ionic/app-scripts": "3.1.0",
"typescript": "2.6.0-rc"
},
我的项目工作正常,因为我添加了firebase依赖项,所以我开始遇到这些错误。
有人可以帮助我吗?
感谢。
答案 0 :(得分:0)
要更新离子,您是否使用此命令或其他任何命令?
npm update -g ionic
在离子论坛中有一个如何升级程序。看看它是否能解决您遇到的这些问题。我希望它有所帮助。
https://forum.ionicframework.com/t/upgrading-existing-ionic-project-to-latest-version/95224/3