Run & Debug Node.js Command Line Application With User Input

Hello, how can I capture user input in a command line application developed with Node.js and Inquirer Package? The integrated WebStorm terminal window doesn't capture any user input, and the option and the 'Use Console Input' option from the console toolbar seems to have been removed after 2018 update.

1
4 comments

there are 2 consoles now: the Console tab accepts stdin; Debugger Console is for expressions evaluation.

Just enter your answers once the prompt appear:

2
Avatar
Permanently deleted user

Yes but, there's a problem: the console doesn't appear to capture arrow input's for the NPM Inquirer Module to navigate over the command line options.

0

Known issue, https://youtrack.jetbrains.com/issue/WEB-13727

The problem is that Node.js Run console is non-tty, because WebStorm launches Node.js process with I/O redirection

0
Avatar
Permanently deleted user

Thank you, everything makes sense now.

0

Please sign in to leave a comment.