angular flex-layout error : has no exported member ɵNgClassImpl error

angular flex-layout error : has no exported member ɵNgClassImpl error

在我上一个 Mean stack 项目中,我使用了 angular flex 布局并且它运行良好

我用 angular 7 开始了一个新项目,包括 flex layout 8(测试版)并得到了以下错误


    ERROR in 
    node_modules/@angular/flexlayout/extended/typings/class/class.d.ts(9,19): 
    error TS2305: Module '".../.../node_modules/@angular/common/common"' 
    has no exported member 'ɵNgClassImpl' 

这是我的 package.json 依赖项:

"dependencies": {
   "@angular/animations": "~7.2.0",
   "@angular/cdk": "^7.3.7",
   "@angular/common": "~7.2.0",
   "@angular/compiler": "~7.2.0",
   "@angular/core": "~7.2.0",
   "@angular/flex-layout": "^8.0.0-beta.25",
   "@angular/forms": "~7.2.0",
   "@angular/http": "^7.2.15",
   "@angular/material": "^7.3.7",
   "@angular/platform-browser": "~7.2.0",
   "@angular/platform-browser-dynamic": "~7.2.0",
   "@angular/router": "~7.2.0",
   "@ng-bootstrap/ng-bootstrap": "^4.1.3",
   "bootstrap": "^4.3.1",
   "core-js": "^2.5.4",
   "hammerjs": "^2.0.8",
   "jquery": "^3.4.1",
   "material-icons": "^0.3.1",
   "popper.js": "^1.15.0",
   "rxjs": "~6.3.3",
   "tslib": "^1.9.0",
   "zone.js": "~0.8.26"
 },

任何人都可以解释为什么会这样吗?它适用于 flex-layout 7.0

Flex Layout v8 仅适用于 Angular v8。返回 V7

对于Angular9

安装 9.x 版本的 flex-layout

npm install --save @angular/flex-layout@9.0.0-beta.29

添加所需的依赖项:

npm install tslib --save

https://github.com/angular/flex-layout/blob/master/CHANGELOG.md