NPM-BIN(1)

💖 npm-bin — the NAME section (yes bestie we're doing this)

okay so <rainbow>npm-bin</rainbow> — that's the name, that's the manual page, section 1. And what does it do? It displays the npm bin folder. That's it. That's the whole gig. She's a one-trick pony and honestly? She ate. 💅


🦋 Synopsis

npm bin [-g|--global]
not me needing you to clock this immediately: this command is unaware of workspaces. Like, it does not know they exist. It will not be acknowledging them. Zero awareness. 🙈

✨ Description

Print the folder where npm will install executables.

that's the tea. that's literally the entire description. go off, minimal queen. 👑


🎀 Configuration

okay so this next bit is autogenerated, so don't come for me:

<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> <!-- automatically
generated, do not edit manually --> <!-- see
lib/utils/config/definitions.js -->

🌸 global

  • Default: false
  • Type: Boolean

So when this is on, npm operates in "global" mode — meaning packages get installed into the prefix folder instead of the current working directory. If you want the full rundown on how those two behave differently, run npm help folders, bestie. 🫶

Here's what actually changes when global mode is on:

  • packages are installed into the {prefix}/lib/node_modules folder, instead of the current working directory.
  • bin files are linked to {prefix}/bin
  • man pages are linked to {prefix}/share/man

and then, of course, the little epilogue:

<!-- automatically generated, do not edit manually --> <!-- see
lib/utils/config/definitions.js -->
<!-- AUTOGENERATED CONFIG DESCRIPTIONS END -->

👑 See Also

  • npm help prefix
  • npm help root
  • npm help folders
  • npm help config
  • npm help npmrc

and that's the whole page, bestie!! 🌈✨ one little command, one little folder path, and a whole lot of global-mode lore. iykyk.

cute sign-off moment: this page is from the NPM-BIN(1) manual, and the footer was genuinely just... undefined NaN 💀 not a date, not a version, just vibes. iconic honestly. go check your bin folder. mwah. 🎀💖🦋

📦 where this page comes from