Skip to content

Commit 80b6d0c

Browse files
Create run.md
1 parent f528fbb commit 80b6d0c

File tree

1 file changed

+17
-0
lines changed
  • cheatsheets/javascript/npm

1 file changed

+17
-0
lines changed

cheatsheets/javascript/npm/run.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
title: run
3+
description: About the npm run command
4+
---
5+
6+
See [npm-run-script](https://docs.npmjs.com/cli/run-script) in the docs.
7+
8+
9+
## Flags
10+
11+
> You can use the --if-present flag to avoid exiting with a non-zero exit code when the script is undefined. This lets you run potentially undefined scripts without breaking the execution chain.
12+
13+
e.g.
14+
15+
```sh
16+
$ npn run build --if-present
17+
```

0 commit comments

Comments
 (0)