title: Node.js "on" function - What does it do?
body: <pre><code> var rd = readline.createInterface({
      input: fs.createReadStream(file),
      output: process.stdout,
      terminal: false
  });
  
  rd.on('line', function(line) {
  </code></pre>
  
  <p>And is any way how to make "on" working synchronous. Code inside "on" loop need to be done before executing loop again. Is any way how to do that?</p>