DEV Community

Discussion on: 📦 npm vs Yarn vs pnpm – Which Package Manager Should You Use in 2025?

Collapse
 
jasperfue profile image
Jasper FĂĽlle

What are your sources? I believe some things are not true:

  1. yarn by default doesn't use node_modules anymore but pnp-loaders
  2. Even the pnpm Website shows that yarnPnP is the fastest package Manager (pnpm.io/benchmarks)
  3. Yarn is as disk-efficient as pnpm (yarnpkg.com/features/pnp#shared-in...)

You can of corse correct me if I'm wrong

Collapse
 
ladoxer profile image
Muhammed Labeeb

Good points — you’re mostly right!

Yarn Berry (v2+) does default to Plug’n’Play now, though many teams still switch back to nodeLinker: node-modules for tool compatibility. So “doesn’t use node_modules anymore” is true by default, but not universal.

And yeah, pnpm’s own benchmarks actually show Yarn PnP performing slightly faster in certain cold-install cases — mostly because it skips creating a node_modules tree. But in real-world usage (cached installs, CI/CD, or big monorepos), pnpm still tends to come out ahead thanks to its hard-linking and store reuse.

On disk efficiency, I agree — both Yarn PnP and pnpm are great now, since they both use a global content-addressable store. The main difference is pnpm achieves that while staying 100% Node-compatible, whereas Yarn’s PnP needs extra tooling support.

So yeah, Yarn PnP is technically amazing, but pnpm often wins in practicality

Collapse
 
milady_shady_395bd81efdf5 profile image
Info Comment hidden by post author - thread only visible in this permalink
Milady Shady

This is AI slop..

Some comments have been hidden by the post's author - find out more