Error when adding the NGB_ALERT_DIRECTIVES from ng-bootstrap to an Angular-CLI project -


i try to add alert directive (ngb_alert_directives) of ng-bootstrap angular-cli project. followed steps described @ https://stackoverflow.com/a/38413274/1596547.

the preceding results in following error:

exception: can't resolve parameters ngbdismissiblealert: (templateref, viewcontainerref, injector, ?, renderer). 

how fix above , related precompile option? see: precompile fails when adding ng-bootstrap angular-cli project

the issue related version of angular, updating angular angular2 rc4 solved it.

in in package.json of angular-cli use following dependencies:

  "dependencies": {     "@angular/common": "2.0.0-rc.4",     "@angular/compiler": "2.0.0-rc.4",     "@angular/core": "2.0.0-rc.4",     "@angular/forms": "0.2.0",     "@angular/http": "2.0.0-rc.4",     "@angular/platform-browser": "2.0.0-rc.4",     "@angular/platform-browser-dynamic": "2.0.0-rc.4",     "@angular/router": "3.0.0-alpha.8",     "@ng-bootstrap/ng-bootstrap": "^1.0.0-alpha.1",     "es6-shim": "0.35.1",     "ng2-bootstrap": "^1.0.24",     "reflect-metadata": "0.1.3",     "rxjs": "5.0.0-beta.6",     "systemjs": "0.19.26",     "zone.js": "0.6.12"   }, 

run npm update , issue solved. error not related precompile option.


Comments