mirror of
https://github.com/ENSL/ensl_gathers.git
synced 2025-02-17 01:12:20 +00:00
13 lines
No EOL
315 B
JavaScript
13 lines
No EOL
315 B
JavaScript
"use strict";
|
|
|
|
module.exports = function (io) {
|
|
io.on('connection', function (socket) {
|
|
socket.emit('welcome', { hello: 'world' });
|
|
// socket.on('my other event', function (data) {
|
|
// console.log(data);
|
|
// });
|
|
socket.on('disconnect', function () {
|
|
io.emit('user disconnected');
|
|
});
|
|
});
|
|
}; |