Requested module '@angular/compiler' does not provide an export named 'TmplAstBoundDeferredTrigger'

148 views Asked by At

I have an angular 16.1.0 project and it was working fine, after restarting vscode and running ng serve command i have this error even i deleted node_modules folder, cleared cache then reinstalled packages:

The requested module '@angular/compiler' does not provide an export named 'TmplAstBoundDeferredTrigger'

this is my package.json file:

{
  "name": "oz-main-site",
  "version": "0.0.0",
  "scripts": {
    "ng": "ng",
    "start": "ng serve",
    "build": "ng build",
    "watch": "ng build --watch --configuration development",
    "test": "ng test"
  },
  "private": true,
  "dependencies": {
    "@angular/animations": "^16.1.0",
    "@angular/common": "^16.1.0",
    "@angular/compiler": "^16.1.0",
    "@angular/core": "^16.1.0",
    "@angular/forms": "^16.1.0",
    "@angular/localize": "^16.2.12",
    "@angular/material": "^16.0.2",
    "@angular/platform-browser": "^16.1.0",
    "@angular/platform-browser-dynamic": "^16.1.0",
    "@angular/router": "^16.1.0",
    "@ng-bootstrap/ng-bootstrap": "^15.1.2",
    "bootstrap": "^5.3.0",
    "bootstrap-icons": "^1.10.5",
    "hammerjs": "^2.0.8",
    "jquery": "^3.7.1",
    "ngx-owl-carousel-o": "^16.0.0",
    "remixicon": "^3.5.0",
    "rxjs": "~7.8.0",
    "swiper": "^8.4.7",
    "tslib": "^2.3.0",
    "zone.js": "~0.13.0"
  },
  "devDependencies": {
    "@angular-devkit/build-angular": "^16.1.0",
    "@angular/cli": "~16.1.0",
    "@angular/compiler-cli": "^16.1.0",
    "@types/hammerjs": "^2.0.45",
    "@types/jasmine": "~4.3.0",
    "jasmine-core": "~4.6.0",
    "karma": "~6.4.0",
    "karma-chrome-launcher": "~3.2.0",
    "karma-coverage": "~2.2.0",
    "karma-jasmine": "~5.1.0",
    "karma-jasmine-html-reporter": "~2.1.0",
    "typescript": "~5.1.3"
  }
}

this is what ng version shows:

Angular CLI: 14.2.6 
Node: 16.14.2 
Package Manager: 
npm 8.5.0 OS: win32 x64
 
 Angular: undefined ...
 
 Package                      Version
 ------------------------------------------------------ 
@angular-devkit/architect    0.1402.6 
@angular-devkit/core         14.2.6 
@angular-devkit/schematics   14.2.6 
@schematics/angular          14.2.6
1

There are 1 answers

1
ΩmegaMan On

The @angular/compiler-cli package must be in unison with the other framework packages, so it needs to be updated to 14.2.6. Either update all to latest version or pull that specific version down from NPM.