close

[Fixed] ERESOLVE Unable to resolve dependency tree error when installing npm packages

Today We are Going To Solve ERESOLVE Unable to resolve dependency tree error when installing npm packages in Javascript. Here we will Discuss All Possible Solutions and How this error Occurs So let’s get started with this Article.

How to Fix ERESOLVE Unable to resolve dependency tree error when installing npm packages Error?

  1. How to Fix ERESOLVE Unable to resolve dependency tree error when installing npm packages Error?

    To Fix ERESOLVE Unable to resolve dependency tree error when installing npm packages Error just Run this command. To solve this error you can try this below command: npm install --save --legacy-peer-deps.

  2. ERESOLVE Unable to resolve dependency tree error when installing npm packages

    To Fix ERESOLVE Unable to resolve dependency tree error when installing npm packages Error just use the --legacy-peer-deps. Here just use the --legacy-peer-deps in your command line. this will help to set more permanently as a config option:
    npm config set legacy-peer-deps true

Solution 1 : Run this command

To solve this error you can try this below command:

npm install --save --legacy-peer-deps

Solution 2 : use the --legacy-peer-deps

Here just use the --legacy-peer-deps in your command line. this will help to set more permanently as a config option:

npm config set legacy-peer-deps true

Solution 3 : Use the command with force

Use the command with force just like below :

npm install –force @your-npm-package

Solution 4 : Remove the node modules

To solve this error first of all remove the node modules and package-lock.json file and after doing this you have to run npm cache clean --force this command. This will solve your error.

Conclusion

So these were all possible solutions to this error. I hope your error has been solved by this article. In the comments, tell us which solution worked? If you liked our article, please share it on your social media and comment on your suggestions. Thank you.

Also Read This Solutions

Leave a Comment