How to use the socket.io function in socket

To help you get started, we’ve selected a few socket examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github tan-tan-kanarek / mediasoup-server / lib / server.js View on Github external
startSocketIoServer() {
		this.io = socketIO(this.webServer);
		this.io.on('connection', (socket) => {
			const connection = new WebRtcConnection(this, socket);
			this.emit('new-connection', connection);
		});
	}
}
github Siot / PaWebControl / src / backend / server.ts View on Github external
constructor() {
    this.app = express();
    this.server = http.createServer(this.app);
    this.io = SocketIO(this.server);
    this.listen();
  }
github tan-tan-kanarek / mediasoup-server / server.js View on Github external
startSocketIoServer() {
		this.io = socketIO(this.webServer);
		this.io.on('connection', function(socket){
			new Connection(server, socket);
		});
	}
github muddydixon / ansibrest / lib / ansibrest.js View on Github external
socket(server){
    const io = this.websocket.io = IO(server);
    io.on("connection", socket =>{
      socket.on("disconnect", ()=>{
      });
    });
  }

socket

Socket is a connect clone for simple socket based applications

MIT
Latest version published 12 years ago

Package Health Score

40 / 100
Full package analysis