title: How do I detect whether a key is pressed in node.js?
body: <p>I have a little utility written in node.js that does some real-time data capture. I'd like to augment it so it also records whether a particular key is pressed on the keyboard at which time during the capture. (This allows me to "mark" the time in the data capture when some event happened).</p>
  
  <p>But how do I detect whether a given key is pressed/down on the keyboard from node.js? Something like readline won't work because it's line-based, and waits until CR is entered. (The capture needs to continue in real time.) Instead, it needs to access the keyboard on a fairly low level to get "the state of key X right now", returning pressed or not-pressed.</p>
  
  <p>Is there such a thing in node.js?</p>