Ask coding questions

← Back to all posts
Why is keypress not working Nodejs
h
Vandesm14 (692)

For the repl https://repl.it/@Vandesm14/Terminal-Editor-Demo
It returns an object, and does not ask for input nor does it log the keypress to the console. What is wrong with the code?

Answered by mat1 (2509) [earned 5 cycles]
View Answer
Commentshotnewtop
mat1 (2509)

The default Node.js console currently. does not support getting key presses due to it using the old terminal. You can use the new terminal by using repl.run

Please upvote my comment if it was helpful or useful. Thanks!