Run a script declared in package.json.
npm run <script>Run a script declared in package.json.
npm run <script>Run a script declared in package.json.
npm run <script>| Option / clause | Description |
|---|---|
<script> | Run the named script from package.json. |
--if-present | Do not fail if the requested script is absent. |
--workspace <name> | Run the script in a selected workspace. |
--workspaces | Run the script in configured workspaces. |
-- <args> | Pass subsequent arguments to the script. |
Review a command and its target before running it. Commands that alter files, services, accounts, disks, permissions or databases may be difficult to reverse. Test in a safe environment and keep backups.