Unable to install bootstrap in Angular project using ng add @ng-bootstrap/ng-bootstrap

152 views Asked by At

I'm having these errors:

Using package manager: npm √ Found compatible package version: @ng-bootstrap/[email protected]. √ Package information loaded.

The package @ng-bootstrap/[email protected] will be installed and executed. Would you like to proceed? Yes npm ERR! code ERESOLVE npm ERR! ERESOLVE could not resolve npm ERR! npm ERR! While resolving: [email protected] npm ERR! Found: @angular/[email protected] npm ERR! node_modules/@angular/core npm ERR! peer @angular/core@"15.2.2" from @angular/[email protected] npm ERR! node_modules/@angular/animations npm ERR! peerOptional @angular/animations@"15.2.2" from @angular/[email protected] npm ERR!
node_modules/@angular/platform-browser npm ERR! peer @angular/platform-browser@"15.2.2" from @angular/[email protected] npm ERR! node_modules/@angular/forms npm ERR! peer @angular/forms@"^15.0.0" from [email protected] npm ERR!
node_modules/ngx-bootstrap npm ERR! 1 more (the root project) npm ERR! 3 more (@angular/platform-browser-dynamic, @angular/router, the root project) npm ERR! peer @angular/animations@"^15.0.0" from [email protected] npm ERR!
node_modules/ngx-bootstrap npm ERR! ngx-bootstrap@"^10.2.0" from the root project npm ERR! 1 more (the root project) npm ERR!
peer @angular/core@"15.2.2" from @angular/[email protected] npm ERR!
node_modules/@angular/common npm ERR! peer @angular/common@"15.2.2" from @angular/[email protected] npm ERR!
node_modules/@angular/forms npm ERR! peer @angular/forms@"^15.0.0" from [email protected] npm ERR!
node_modules/ngx-bootstrap npm ERR! ngx-bootstrap@"^10.2.0" from the root project npm ERR! 1 more (the root project) npm ERR! peer @angular/common@"15.2.2" from @angular/[email protected] npm ERR!
node_modules/@angular/platform-browser npm ERR! peer @angular/platform-browser@"15.2.2" from @angular/[email protected] npm ERR! node_modules/@angular/forms npm ERR! peer @angular/forms@"^15.0.0" from [email protected] npm ERR!
node_modules/ngx-bootstrap npm ERR! 1 more (the root project) npm ERR! 3 more (@angular/platform-browser-dynamic, @angular/router, the root project) npm ERR! 4 more (@angular/platform-browser-dynamic, @angular/router, ...) npm ERR! 7 more (@angular/compiler, @angular/forms, ...) npm ERR! npm ERR! Could not resolve dependency: npm ERR! @ng-bootstrap/ng-bootstrap@"14.0.1" from the root project npm ERR! npm ERR! Conflicting peer dependency: @angular/[email protected] npm ERR! node_modules/@angular/core npm ERR!
peer @angular/core@"15.2.3" from @angular/[email protected] npm ERR!
node_modules/@angular/forms npm ERR! @angular/forms@"^15.2.0" from the root project npm ERR! peer @angular/forms@"^15.0.0" from @ng-bootstrap/[email protected] npm ERR!
node_modules/@ng-bootstrap/ng-bootstrap npm ERR!
@ng-bootstrap/ng-bootstrap@"14.0.1" from the root project npm ERR! npm ERR! Fix the upstream dependency conflict, or retry npm ERR! this command with --force or --legacy-peer-deps npm ERR! to accept an incorrect (and potentially broken) dependency resolution. npm ERR! npm ERR! npm ERR! For a full report see: npm ERR! C:\Users\m4357\AppData\Local\npm-cache_logs\2023-03-22T09_51_52_268Z-eresolve-report.txt

npm ERR! A complete log of this run can be found in: npm ERR!
C:\Users\m4357\AppData\Local\npm-cache_logs\2023-03-22T09_51_52_268Z-debug-0.log × Packages installation failed, see above.

0

There are 0 answers