如何在调试器界面中将内容输入脚本的stdin?

use*_*725 8 debugging stdin node.js

我跑了:

node debug f.js
Run Code Online (Sandbox Code Playgroud)

现在我有一个:

debug>
Run Code Online (Sandbox Code Playgroud)

提示.如何在我键入的终端之间切换被解释为调试命令并将其输入到脚本的stdin中?

cda*_*nge 0

根据 Node.js 文档,

从命令行运行此程序将在 stdin 上启动 REPL

这意味着如果您的应用程序需要 stdin,则必须通过其他方式针对该进程启动 repl。请参阅https://nodejs.org/api/repl.html

我发现使用 ms Visual Studio Code 或 Node-Inspector 满足了我的需求