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
{{ message }}
Repository navigation
ERESOLVE: @angular-builders/jest@20 depends on deprecated @angular/platform-browser-dynamic peer #2387
Installing @angular-builders/jest@20 in a fresh Angular 20 workspace fails with an ERESOLVE dependency conflict. The root cause is that @angular-builders/jest still declares a peer dependency on @angular/platform-browser-dynamic, which was deprecated by the Angular team as part of the Angular 19 → 20 migration (its functionality was folded into @angular/platform-browser). The deprecated package is pinned to an older @angular/common peer range, which conflicts with the ^20.3.0 range resolved for the rest of a fresh Angular 20 workspace.
Minimal Reproduction
Create a new Angular 20 app:
npx @angular/cli@20 new ng20 --skip-git
cd ng20
Install the package:
npm i -D @angular-builders/jest@20
Error
npm i -D @angular-builders/jest@20
npm error code ERESOLVE
npm error ERESOLVE unable to resolve dependency tree
npm error
npm error While resolving: ng20@0.0.0
npm error Found: @angular/common@20.3.27
npm error node_modules/@angular/common
npm error @angular/common@"^20.3.0" from the root project
npm error peer @angular/common@"20.3.27" from @angular/platform-browser@20.3.27
npm error node_modules/@angular/platform-browser
npm error @angular/platform-browser@"^20.3.0" from the root project
npm error peerOptional @angular/platform-browser@"^20.0.0" from @angular-devkit/build-angular@20.3.33
npm error node_modules/@angular-devkit/build-angular
npm error peer @angular-devkit/build-angular@"^20.0.0" from @angular-builders/jest@20.0.0
npm error node_modules/@angular-builders/jest
npm error dev @angular-builders/jest@"20" from the root project
npm error 2 more (@angular/platform-server, @angular/router)
npm error 3 more (@angular/platform-server, @angular/ssr, @angular/router)
npm error
npm error Could not resolve dependency:
npm error peer @angular/common@"20.0.7" from @angular/platform-browser-dynamic@20.0.7
npm error node_modules/@angular/platform-browser-dynamic
npm error peer @angular/platform-browser-dynamic@"^20.0.0" from @angular-builders/jest@20.0.0
npm error node_modules/@angular-builders/jest
npm error dev @angular-builders/jest@"20" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution.
Expected Behavior
npm install should succeed without needing --force or --legacy-peer-deps.
Environment
Libs
- @angular/core: 20.3.27
- @angular/cli: 20.3.33
- @angular-devkit/build-angular: N/A - using the esbuild and Vite-based `@angular/build@20.3.27` package instead
- @angular-builders/jest: 20.0.0
Tooling
- Node.js: v24.16.0
- npm: 11.13.0
- OS: Windows
@angular/platform-browser-dynamic was deprecated by the Angular team in the Angular 19 → 20 release. @angular-builders/jest@20.0.0 still declares a peer dependency on @angular/platform-browser-dynamic@^20.0.0, which resolves to @angular/platform-browser-dynamic@20.0.7, pinned to @angular/common@20.0.7 — conflicting with the ^20.3.0 range resolved elsewhere in a fresh Angular 20 workspace.
Suggested Fix
Remove (or relax/make optional) the peer dependency on the deprecated @angular/platform-browser-dynamic package in @angular-builders/jest, since it is no longer required for Angular 20 projects.
Activity
akaustav commentedon Aug 12, 2026
Root Cause
@angular/platform-browser-dynamicwas deprecated by the Angular team in the Angular 19 → 20 release.@angular-builders/jest@20.0.0still declares a peer dependency on@angular/platform-browser-dynamic@^20.0.0, which resolves to@angular/platform-browser-dynamic@20.0.7, pinned to@angular/common@20.0.7— conflicting with the^20.3.0range resolved elsewhere in a fresh Angular 20 workspace.Suggested Fix
Remove (or relax/make optional) the peer dependency on the deprecated
@angular/platform-browser-dynamicpackage in@angular-builders/jest, since it is no longer required for Angular 20 projects.