how repl works in node.js