const re = readline.createInterface({
input: process.stdin,
output: process.stdout,
});
re.on("line", (order) => {
if (!this.checkIsCorrectOrder(order)) {
console.log("Wrong");
return;
}
someFun(order)
}).on("close", () => {
process.exit();
});
... ohter Asynchronous
let count = 0
setInterval(()=>{
console.log(count++)
},1000)
I want to type while avoiding overlapping readline and console.log
how can i do that?
Is there any other way besides readline??? thanks!!
