pnpm
Install pnpm in WSL with its standalone script and use it as your Node.js package manager.
pnpm is the package manager Vinicunca projects use. It keeps one content-addressable store on disk and hard-links files into each project's node_modules, so shared packages are not copied per repo.
Install it inside WSL with the standalone script. Do not use Corepack: Node.js 25+ no longer bundles it, and even on Node 24 it is experimental and easy to get out of date.
Install
curl -fsSL https://get.pnpm.io/install.sh | sh -
The script unpacks pnpm under ~/.local/share/pnpm and appends to ~/.zshrc. Open a new terminal tab (or source ~/.zshrc) and confirm:
pnpm --version
Pin a major if you need to:
curl -fsSL https://get.pnpm.io/install.sh | env PNPM_VERSION=10 sh -
Never run the installer or
pnpm with sudo. pnpm 12 refuses self-update and similar commands under root (ERR_PNPM_SUDO_NOT_SUPPORTED) because its store and config live in your home directory.Why this instead of Corepack or npm?
- Corepack stopped shipping with Node.js 25. On older lines you still had to
corepack enable, and signatures have been stale enough that pnpm's own docs tell you to update Corepack first. npm i -g pnpmworks, but then pnpm's version is tied to whichever Node fnm has selected. The standalone binary stays on yourPATHacross Node upgrades.- Install in Linux, not with WinGet's Windows pnpm. Windows Defender has also been known to quarantine that Windows binary; you do not need it if all projects live in WSL.
Everyday commands
pnpm install # install from pnpm-lock.yaml
pnpm add vue # dependency
pnpm add -D vitest # dev dependency
pnpm remove vue
pnpm update
pnpm run dev # or: pnpm dev
pnpm dlx nuxi@latest init my-app
pnpm self-update # update the pnpm binary
The store location is pnpm store path (typically under your Linux home). Keep projects in the Linux filesystem so installs stay fast — see WSL.