pnpm Config and Store/Use hoisted node_modules linker

Switch to a hoisted node_modules layout if needed for compatibility.

Section: Node Linkers and Installation Modes

Use hoisted node_modules linker

bash
bash
pnpm config set node-linker hoisted
Explanation

Switch to a hoisted node_modules layout if needed for compatibility.

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing Node Linkers and Installation Modes
Use isolated linker
Use pnpm's default strict linking model.
OpenIn sheetbashsame section
Enable shamefully-hoist
Hoist dependencies more aggressively for legacy tooling compatibility.
OpenIn sheetbashsame section
Prefer offline installs
Use cached metadata and packages when possible.
OpenIn sheetbashsame section
Configure store directory
Pin the store location explicitly.
OpenIn sheetbashsame section
Get config value
Read a pnpm configuration value.
OpenIn sheetbash2 tag match
Set config value
Set a pnpm configuration value.
OpenIn sheetbash2 tag match