Huzaifa
Huzaifa

Reputation: 121

Fix the upstream dependency conflict in Angular

I know the answer to this question is already available on SOF but I can't use --legacy-peer-deps or --force on my production server that's why I want to learn the real reason behind why this error occurs and want to fix it.

On installing some libraries I am getting the following error, does anyone know how to resolve it without forcing it? I am working on Angular 14, If need be I can downgrade too.

enter image description here

enter image description here

Upvotes: 1

Views: 3547

Answers (2)

red1dev
red1dev

Reputation: 74

I had the same problem in angular 14, so I tried this library ngx-mat-intl-tel-input and it worked for me

Upvotes: 0

Riscie
Riscie

Reputation: 4689

The reason you get this error is because your dependency [email protected] is depending on an @angular/common version between 8 - 13. But your app is on angular 14 with @angular/[email protected].

You have two options:

  1. If possible, upgrade ngx-intl-tel-input to a newer version, that makes use of @angular/[email protected]

  2. Downgrade your app to angular 13.

Edit You've added a second image. Here it seems you are just missing @angular/animations. Try npm i @angular/animations

Upvotes: 0

Related Questions