Created
May 11, 2018 05:39
-
-
Save knrt10/f8934ea1f3fa8b8207f29f1f95b7b288 to your computer and use it in GitHub Desktop.
Enabling keypress
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const stdin = process.stdin | |
| const stdout = process.stdout | |
| stdin.setRawMode(true) | |
| stdin.resume() | |
| require('readline').emitKeypressEvents(stdin) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment