找不到&#; rx / rx.all'的类型定义文件

时间:2017-02-17 11:37:25

标签: angular-material2

我试图让材料2选择在我的应用程序中工作,但看起来我错过了一些东西。

我一直收到错误

"Error  TS2688  Build:Cannot find type definition file for 'rx/rx.all'"

以下是package.json

{
"version": "1.0.0",
 "name": "reportbook",
  "dependencies": {
   "@angular/common": "~2.4.0",
    "@angular/compiler": "~2.4.0",
    "@angular/core": "~2.4.0",
    "@angular/forms": "~2.4.0",
    "@angular/http": "~2.4.0",
    "@angular/material": "~2.0.0-beta.2",
    "@angular/platform-browser": "~2.4.0",
    "@angular/platform-browser-dynamic": "~2.4.0",
    "@angular/router": "~3.4.0",
   "@angular/upgrade": "~2.4.0",
    "@types/core-js": "~0.9.34",
    "@types/hammerjs": "~2.0.33",
    "@types/jasmine": "~2.5.43",
    "@types/lodash": "4.14.50",
    "@types/rx": "4.1.1",
    "angular-in-memory-web-api": "~0.2.4",
    "bootstrap": "~3.3.7",
    "core-js": "~2.4.1",
    "hammerjs": "~2.0.8",
    "lodash": "~4.16.6",
    "moment": "~2.16.0",
    "ng2-bootstrap": "~1.3.3",
    "reflect-metadata": "~0.1.8",
    "rxjs": "~5.0.0-beta.12",
    "systemjs": "~0.19.41",
    "zone.js": "~0.7.7"
  },
  "devDependencies": {
    "del": "~2.2.2",
    "gulp": "^3.9.1",
    "gulp-clean": "^0.3.2",
    "gulp-concat": "^2.6.0",
    "gulp-tsc": "^1.2.5",
    "gulp-typescript": "^2.14.1",
    "hammerjs": "^2.0.8",
    "path": "^0.12.7",
    "tslint": "^3.15.1",
    "typescript": "~2.1.6",
    "gulp-sass": "~2.3.2",
    "rimraf": "~2.3.2"
  }
}

如果有人能指出我正确的方向,我将非常感激

1 个答案:

答案 0 :(得分:1)

我遇到了这个问题,并将@ types / rx从4.1.1降级到2.5.34,这似乎有效。