You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ng add @angular/fire
✔ Determining Package Manager
› Using package manager: npm
✔ Searching for compatible package version
› Unable to find compatible package. Using 'latest' tag.
✔ Loading package information from registry
› ⚠ Package has unmet peer dependencies. Adding the package may not succeed.
✔ Confirming installation
✖ Unable to install package
npm error code ERESOLVE
npm error ERESOLVE unable to resolve dependency tree
npm error
npm error While resolving: example@0.0.0
npm error Found: @angular/common@19.1.1
npm error node_modules/@angular/common
npm error @angular/common@"^19.0.0" from the root project
npm error
npm error Could not resolve dependency:
npm error peer @angular/common@"^18.0.0" from @angular/fire@18.0.1
npm error node_modules/@angular/fire
npm error @angular/fire@"18.0.1" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.
npm error
npm error
npm error For a full report see:
npm error C:\Users\pavan\AppData\Local\npm-cache_logs\2025-01-16T15_41_21_682Z-eresolve-report.txt
npm error A complete log of this run can be found in: C:\Users\pavan\AppData\Local\npm-cache_logs\2025-01-16T15_41_21_682Z-debug-0.log
Same issue trying to add to Project with Angular 19.1.1
`$ ng add @angular/fire
✔ Determining Package Manager
› Using package manager: npm
✔ Searching for compatible package version
› Found compatible package version: @angular/fire@19.0.0.
✔ Loading package information from registry
✔ Confirming installation
✖ Unable to install package
npm error code ERESOLVE
npm error ERESOLVE could not resolve
npm error
npm error While resolving: myappname@0.0.0
npm error Found: @angular/core@19.1.1
npm error node_modules/@angular/core
npm error peer @angular/core@"19.1.1" from @angular/animations@19.1.1
npm error node_modules/@angular/animations
npm error peer @angular/animations@"^19.0.0 || ^20.0.0" from @angular/material@19.1.0
npm error node_modules/@angular/material
npm error @angular/material@"^19.1.0" from the root project
npm error peerOptional @angular/animations@"19.1.1" from @angular/platform-browser@19.1.1
npm error node_modules/@angular/platform-browser
npm error peer @angular/platform-browser@"19.1.1" from @angular/forms@19.1.1
npm error node_modules/@angular/forms
npm error peer @angular/forms@"^19.0.0 || ^20.0.0" from @angular/material@19.1.0
npm error node_modules/@angular/material
npm error 1 more (the root project)
npm error 4 more (@angular/material, ...)
npm error 1 more (the root project)
npm error peer @angular/core@"^19.0.0 || ^20.0.0" from @angular/cdk@19.1.0
npm error node_modules/@angular/cdk
npm error peer @angular/cdk@"19.1.0" from @angular/material@19.1.0
npm error node_modules/@angular/material
npm error @angular/material@"^19.1.0" from the root project
npm error @angular/cdk@"^19.1.0" from the root project
npm error 9 more (@angular/common, @angular/compiler, @angular/forms, ...)
npm error
npm error Could not resolve dependency:
npm error @angular/fire@"19.0.0" from the root project
npm error
npm error Conflicting peer dependency: @angular/core@19.1.6
npm error node_modules/@angular/core
npm error peer @angular/core@"19.1.6" from @angular/platform-browser-dynamic@19.1.6
npm error node_modules/@angular/platform-browser-dynamic
npm error @angular/platform-browser-dynamic@"^19.1.0" from the root project
npm error peer @angular/platform-browser-dynamic@"^19.0.0" from @angular/fire@19.0.0
npm error node_modules/@angular/fire
npm error @angular/fire@"19.0.0" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.`
Thanks for reporting this, and to everyone who added their output.
There were two different conflicts in this thread:
The first report came in a few hours before AngularFire 19.0.0 was published, so ng add fell back to 18.0.1, which only supports Angular 18.
The later reports did get 19.0.0. There, npm installed a newer patch of @angular/platform-browser-dynamic (a peer dependency of AngularFire) than the app's @angular/core. Running ng update first, as BaronVonPerko suggested, lines the patches up.
AngularFire no longer has that peer dependency. #3718 removed it, and AngularFire 21.0.0, the current release, depends only on @angular/core, @angular/common and @angular/platform-browser from Angular.
Closing this as fixed. If ng add @angular/fire hits an ERESOLVE error on a current version, please open a new issue with the full npm output.
Activity
google-oss-bot commentedon Jan 16, 2025
This issue does not seem to follow the issue template. Make sure you provide all the required information.
peciulevicius commentedon Jan 16, 2025
I'm having same issue when trying to install it on angular 19
Mayocampo commentedon Feb 13, 2025
Same issue trying to add to Project with Angular 19.1.1
`$ ng add @angular/fire
✔ Determining Package Manager
› Using package manager: npm
✔ Searching for compatible package version
› Found compatible package version: @angular/fire@19.0.0.
✔ Loading package information from registry
✔ Confirming installation
✖ Unable to install package
npm error code ERESOLVE
npm error ERESOLVE could not resolve
npm error
npm error While resolving: myappname@0.0.0
npm error Found: @angular/core@19.1.1
npm error node_modules/@angular/core
npm error peer @angular/core@"19.1.1" from @angular/animations@19.1.1
npm error node_modules/@angular/animations
npm error peer @angular/animations@"^19.0.0 || ^20.0.0" from @angular/material@19.1.0
npm error node_modules/@angular/material
npm error @angular/material@"^19.1.0" from the root project
npm error peerOptional @angular/animations@"19.1.1" from @angular/platform-browser@19.1.1
npm error node_modules/@angular/platform-browser
npm error peer @angular/platform-browser@"19.1.1" from @angular/forms@19.1.1
npm error node_modules/@angular/forms
npm error peer @angular/forms@"^19.0.0 || ^20.0.0" from @angular/material@19.1.0
npm error node_modules/@angular/material
npm error 1 more (the root project)
npm error 4 more (@angular/material, ...)
npm error 1 more (the root project)
npm error peer @angular/core@"^19.0.0 || ^20.0.0" from @angular/cdk@19.1.0
npm error node_modules/@angular/cdk
npm error peer @angular/cdk@"19.1.0" from @angular/material@19.1.0
npm error node_modules/@angular/material
npm error @angular/material@"^19.1.0" from the root project
npm error @angular/cdk@"^19.1.0" from the root project
npm error 9 more (@angular/common, @angular/compiler, @angular/forms, ...)
npm error
npm error Could not resolve dependency:
npm error @angular/fire@"19.0.0" from the root project
npm error
npm error Conflicting peer dependency: @angular/core@19.1.6
npm error node_modules/@angular/core
npm error peer @angular/core@"19.1.6" from @angular/platform-browser-dynamic@19.1.6
npm error node_modules/@angular/platform-browser-dynamic
npm error @angular/platform-browser-dynamic@"^19.1.0" from the root project
npm error peer @angular/platform-browser-dynamic@"^19.0.0" from @angular/fire@19.0.0
npm error node_modules/@angular/fire
npm error @angular/fire@"19.0.0" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.`
Sourdeval commentedon Mar 20, 2025
Same issue here, some workaround to solve it ? I'm beginner
--force and --legacy-peer-deps didn't work
ulver2812 commentedon Apr 6, 2025
Same issue here:
BaronVonPerko commentedon Apr 8, 2025
I had this same issue and was able to resolve it.
Run
ng updateThen, update all of the packages (these will probably just be minors/patches).
Then, run
ng add @angular/fire. Hope this helps!armando-navarro commentedon Dec 4, 2026
Thanks for reporting this, and to everyone who added their output.
There were two different conflicts in this thread:
ng addfell back to 18.0.1, which only supports Angular 18.@angular/platform-browser-dynamic(a peer dependency of AngularFire) than the app's@angular/core. Runningng updatefirst, as BaronVonPerko suggested, lines the patches up.AngularFire no longer has that peer dependency. #3718 removed it, and AngularFire 21.0.0, the current release, depends only on
@angular/core,@angular/commonand@angular/platform-browserfrom Angular.Closing this as fixed. If
ng add @angular/firehits an ERESOLVE error on a current version, please open a new issue with the full npm output.