You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I ran this sample code using the npx vite-node index.ts hello command.
Expected
"Hello World!" is being printed.
Actual
"Hello World!" is not being printed.There are no errors.The help() and version() commands are working as expected.
Possible Solutions
Upon investigation, I found that using parse(process.argv) results in "Hello World!" being printed when no arguments are provided, while the parsed object logged in both cases shows the differences:
It appears that the code processes arguments differently when no arguments are provided, and it seems to be related to Deno's Deno.args.
I'm not familiar with Deno, so this difference is a puzzling.
Info
CAC version: 6.7.14
Reproduction link:
The text was updated successfully, but these errors were encountered:
Issue Type
Hi. I am attempting to create my first Node.js CLI program.
I ran this sample code using the
npx vite-node index.ts hello
command.Expected
"Hello World!" is being printed.
Actual
"Hello World!" is not being printed.There are no errors.The help() and version() commands are working as expected.
Possible Solutions
Upon investigation, I found that using parse(process.argv) results in "Hello World!" being printed when no arguments are provided, while the
parsed
object logged in both cases shows the differences:No arguments provided (incorrect)
Using
process.argv
as arguments (correct)It appears that the code processes arguments differently when no arguments are provided, and it seems to be related to Deno's Deno.args.
I'm not familiar with Deno, so this difference is a puzzling.
Info
The text was updated successfully, but these errors were encountered: