Reverting Angular Upgrade from 14 to 13 Causes Peer Dependency Conflicts in npm Update

Downgrading to Angular 13 results in npm update failing due to dependency mismatches. For example, consider this simplified configuration:

{
  "frameworkModule": "[email protected]"
}

Why is Angular CDK demanding [email protected]?

hey, i hit this too. i ended up forcing the old cdk ver that works with angular 13 in my package json. not clean but it solved the issue for me. good luck!

hey, i had this issue too. angular cdk was compiled for angular-common@14 so downgrading angular gives conflicts. maybe try using an older cdk version or patching the dependency by forcing a compatible version via your package manager. good luck!

Considering my experience with Angular version mismatches, I believe Angular CDK was updated alongside Angular 14 and built with dependencies that target the newest versions of core libraries like angular-common. When reverting to Angular 13, this difference creates conflicts because the package expects certain features and updates that are not present in the older release. The CDK is most likely compiled with version 14 specifics in mind, so using a version of Angular that lacks these updates forces npm to indicate a dependency mismatch. It might be useful to search for a CDK version that supports Angular 13 or consider reverting related dependencies.

Downgrading Angular can be more challenging than it first appears, particularly when core modules are compiled against newer versions. In my experience, the Angular CDK tends to rely on advanced features available only in Angular 14’s angular-common. When reverting to Angular 13, these dependencies become out of sync, resulting in conflicts. I encountered a similar issue and found that resolving these dependency mismatches required either aligning all related packages to the older version or planning an update strategy that addressed these version dependencies holistically.

In my experience dealing with Angular version rollbacks, the problem originates from the fact that library maintainers update their packages to work with the latest features and fixes. The Angular CDK was targeted at Angular 14, and even minor changes in dependencies like angular-common can alter functionality. I encountered similar issues where reverting to Angular 13 forced many interdependent packages into incompatibility. It might be worth exploring the official release notes for the CDK to backtrack compatible versions or checking community patches that address these version conflicts.