Skip to content

docs: update argument passing example by replacing the dev script with a port configuration explanation - #51

Merged
avivkeller merged 1 commit into
nodejs:mainfrom
Venkat-Entropik:fix/node-run-flag-argument-forwarding
May 12, 2026
Merged

docs: update argument passing example by replacing the dev script with a port configuration explanation#51
avivkeller merged 1 commit into
nodejs:mainfrom
Venkat-Entropik:fix/node-run-flag-argument-forwarding

Conversation

@Venkat-Entropik

@Venkat-Entropik Venkat-Entropik commented Apr 12, 2026

Copy link
Copy Markdown
Contributor

This PR fixes a misleading example in the Node.js docs for the --run flag.

The previous example suggested that arguments like --watch behave as Node.js CLI flags when passed using --, but they are actually forwarded to the script (e.g., node app.js --watch).

Changes:
Removed the confusing example using --watch
Added a clearer example using a custom argument (--port)
Added a note to clarify that arguments passed after -- are not Node.js CLI flags

closes #39

@vercel

vercel Bot commented Apr 12, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
nodejs-learn Ready Ready Preview Apr 12, 2026 3:13am

Request Review

@avivkeller
avivkeller added this pull request to the merge queue May 12, 2026
Merged via the queue into nodejs:main with commit 50bd300 May 12, 2026
2 checks passed
@Venkat-Entropik
Venkat-Entropik deleted the fix/node-run-flag-argument-forwarding branch May 18, 2026 02:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Incorrect CLI flag in CLI learn

2 participants