Skip to content

Instantly share code, notes, and snippets.

@IngIeoAndSpare
Created March 7, 2019 04:47
Show Gist options
  • Save IngIeoAndSpare/a1ac8762833b222dd715100a0757843a to your computer and use it in GitHub Desktop.
Save IngIeoAndSpare/a1ac8762833b222dd715100a0757843a to your computer and use it in GitHub Desktop.
get user input use readline-sync
const readLineSync = require('readline-sync');
var userInput = [],
menuText = [];
function getUserInput() {
// get user input text
for(let consoleLine of menuText) {
userInputData.push(readLineSync.question(consoleLine));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment