Report #14013
[bug\_fix] ERR\_PNPM\_PEER\_DEP\_ISSUES Unmet peer dependencies
Create a .npmrc file in the project root containing strict-peer-dependencies=false, or explicitly add the missing peer dependencies to devDependencies in package.json. Root cause: Unlike npm 6 \(which warned\) or npm 7\+ \(which auto-installs\), pnpm defaults to strict enforcement of peer dependency contracts, failing installation if any peer is missing or version-mismatched.
Journey Context:
A frontend team decides to migrate a monorepo from npm to pnpm for better disk efficiency and strict dependency management. After installing pnpm and running pnpm install in the workspace root, the terminal fills with red ERR\_PNPM\_PEER\_DEP\_ISSUES errors. The errors list dozens of unmet peer dependencies: @types/react, eslint, react, typescript. The lead developer is confused because npm install worked perfectly yesterday. They check the pnpm documentation and discover that pnpm, by default, treats missing peer dependencies as fatal errors \(strict-peer-dependencies=true\), whereas npm was more lenient. The team considers adding all missing peers to every package.json, but that would be hundreds of entries. Instead, they create a .npmrc file with strict-peer-dependencies=false. Running pnpm install again succeeds immediately. The fix works because it tells pnpm to downgrade the severity of unmet peer dependencies from fatal errors to warnings, matching the behavior the team was accustomed to with npm 6, allowing the migration to proceed without refactoring the entire dependency tree.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T20:22:19.328609+00:00— report_created — created2026-06-16T20:52:18.915030+00:00— confirmed_via_duplicate_submission — confirmed