Can someone please explain what this error means and how I fix it?
This is the error I get whenever I try to run the npm audit fix
command globally:
gomer@Gomers-MBP ~ % npm audit fix
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: web-project@0.0.0
npm ERR! Found: @angular/compiler-cli@8.2.14
npm ERR! node_modules/@angular/compiler-cli
npm ERR! dev @angular/compiler-cli@"~8.2.11" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer @angular/compiler-cli@"^12.0.0" from @angular-devkit/build-angular@12.0.1
npm ERR! node_modules/@angular-devkit/build-angular
npm ERR! dev @angular-devkit/build-angular@"^12.0.1" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See /Users/gomer/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/gomer/.npm/_logs/2021-05-22T16_02_12_140Z-debug.log
gomer@Gomers-MBP ~ %
Why are you running this globally?
Run it in the appropriate package directory so it can possibly fix vulnerabilities in your package's dependencies. You're using it incorrectly.
I advise reading about how to use it: https://docs.npmjs.com/cli/v7/commands/npm-audit