iol
iol

Reputation: 37

Web server not starting

I am trying to implement this tutorial.

The problem that i am facing is: I have downloaded node.js and run the command:npm install socket.io, I get this message:image (sorry for the link to the drive but i don't yet have the required rep to post mages)
After that i have run the command node server.js

server.js:

// Generated by CoffeeScript 1.9.1
(function() {
  var io;

  io = require('socket.io').listen(4000);

  io.sockets.on('connection', function(socket) {});

}).call(this);

which is running in cmd prompt but taking forever. Any help would be really appreciated.

Upvotes: 0

Views: 42

Answers (1)

Vasyl Boroviak
Vasyl Boroviak

Reputation: 6138

It should run forever. It's how node.js works. This node process is your server. Your client application will connect to it via your port 4000.

Press Ctrl+C to stop it.

Upvotes: 2

Related Questions