Run NPM script in a different dir #

Last updated March 11, 2026
javascriptnpm

You can run an npm script from a different directory by using the --prefix parameter

npm --prefix <path> run <command>