Watch: Fix "npm ERR! ERESOLVE unable to resolve dependency tree" | Vovy

Watch Vovy do it on a Mac: "npm install fails with ERESOLVE unable to resolve dependency tree, fix it". Vovy reads your npm error, finds the package version clash behind it, and fixes it properly instead of blindly using --force.

"npm install fails with ERESOLVE unable to resolve dependency tree, fix it"

Vovy reads your npm error, finds the package version clash behind it, and fixes it properly instead of blindly using --force.

What happens in the video

  1. Capture the full error: Vovy runs npm install and reads the whole log, not just the red line, to find which two packages disagree.
  2. Explain the clash: A card shows the conflict, like a library that wants React 18 while you have React 19. These are called peer dependencies: packages that must match each other.
  3. Check Node and lockfiles: Vovy confirms your Node version matches the project and checks for mixed lockfiles, like package-lock.json next to bun.lockb.
  4. Apply the smallest fix: Vovy upgrades the outdated package if a compatible version exists, or uses --legacy-peer-deps only when that is the safe choice.
  5. Prove it builds: Vovy reinstalls cleanly, runs npm run build, and shows a diff of what changed in package.json.
Read the step-by-step guide