当我尝试输入命令“npm start”时。我收到了这个错误:
ERROR in Error: Metadata version mismatch for module C:/Users/zack/Desktop/projects/my_project/node_modules/@ng-bootstrap/ng-bootstrap/index.d.ts, found version 4, expected 3, resolving symbol AppModule in C:/Users/zack/Desktop/projects/my_project/src/app/app.module.ts, resolving symbol AppModule in C:/Users/zack/Desktop/projects/my_project/src/app/app.module.ts, resolving symbol AppModule in C:/Users/zack/Desktop/projects/my_project/src/app/app.module.ts
我真的不知道造成这个问题的原因。我已经安装了早期的@ angular / cdk和@ amgular / material到它的最新版本,希望它能解决这个问题,但事实并非如此。
以下是我对package.json的依赖
"dependencies": {
"@angular/common": "^4.0.0",
"@angular/compiler": "^4.0.0",
"@angular/core": "^4.0.0",
"@angular/flex-layout": "2.0.0-beta.8",
"@angular/forms": "^4.0.0",
"@angular/http": "^4.0.0",
"@angular/platform-browser": "^4.0.0",
"@angular/platform-browser-dynamic": "^4.0.0",
"@angular/router": "^4.0.0",
"@ng-bootstrap/ng-bootstrap": "^1.0.0-beta.1",
"@ngtools/json-schema": "^1.1.0",
"angular2-cool-storage": "^3.1.0",
"angular2-image-upload": "^1.0.0-rc.0",
"angular2-ladda": "^1.2.0",
"angular2-moment": "^1.7.0",
"angular2-multiselect-dropdown": "^1.2.6",
"angular2-notifications-lite": "^0.1.2",
"common-tags": "^1.4.0",
"core-js": "^2.4.1",
"font-awesome": "^4.7.0",
"jquery": "^3.2.1",
"lodash": "^4.17.3",
"moment": "^2.18.1",
"ng-block-ui": "^0.9.2",
"ng2-dropdown-multiselect": "^1.2.0",
"ng2-file-drop": "^1.1.0",
"ng2-file-upload": "^1.2.1",
"ng2-file-uploader": "^0.1.4",
"ng2-inputmask": "^0.2.5",
"ng2-pdf-viewer": "^3.0.2",
"ng2-truncate": "^1.3.11",
"ngx-bootstrap": "^2.0.0-beta.7",
"ngx-gallery": "^3.1.3",
"ngx-quill": "^1.2.0",
"rxjs": "^5.1.0",
"swagger-js-codegen": "^1.10.1",
"time-ago-pipe": "^1.2.1",
"zone.js": "^0.8.4"
},