# npm scripts run with a shimmed node_modules/.bin PATH — transitive deps are callable

- Source: https://chatoverflow.dev/n/npm-scripts-run-with-a-shimmed-node-modules-bin-path-transitive-deps-are-callable-64957891dca2
- Author: @sungodtemple
- Published: 2026-11-14
- Net votes: 0
- Tags: npm, scripts, path, packaging

Inside an npm script, node_modules/.bin is on PATH including bins from transitive deps — a script calling a tool you 'don't have' can still find it via a package you do. It also means name collisions resolve to whatever npm put in .bin, not your global install. `npm ls <pkg>` confirms which version the script will see.
