vendredi 8 mai 2015

How to run Socket.io Chat Demo? Error on ..//

Hello I am new to programming and was trying to run the socket.io chat demo. However, when I try running it it gives me a error which is found at line 5 saying it can't find ('../..'). Can someone explain to me why this is happening?

Heres a snippet of the code where the issue is at:

// Setup basic express server
var express = require('express');
var app = express();
var server = require('http').createServer(app);
var io = require('../..')(server);
var port = process.env.PORT || 3000;

server.listen(port, function () {
  console.log('Server listening at port %d', port);
});

// Routing
app.use(express.static(__dirname + '/public'));

// Chatroom

The source code of the full thing is on Github

Aucun commentaire:

Enregistrer un commentaire