Description:
Hello, following a simple and straight forward tutorial. Everything works fine, but I was just curious as to why I'm getting a double request received
when I refresh/access my page?
Part of my code:
function onRequest(request, response){
console.log('request received');
response.writeHead(200, {"Content-Type": "text/plain"});
response.write('Hello world baby');
response.end();
}
//creating server
http.createServer(onRequest).listen(8888);
console.log("server has started");