Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

asking questions javascript in console

var readline = require('readline');

var rl = readline.createInterface({
  input: process.stdin,
  output: process.stdout
});

rl.question("What do you think of node.js? ", function(answer) {
  console.log("Thank you for your valuable feedback:", answer);

  rl.close();
});
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #questions #javascript #console
ADD COMMENT
Topic
Name
6+4 =