chatz/server/socket/index.js
notnull 477b5cd51a added socket.io
- need to add setupProxy to src to proxy requests from dev server to 
backend 
-
2019-07-14 00:25:02 -04:00

11 lines
298 B
JavaScript

module.exports = io => {
console.log('socket initialized', io)
io.on('connection', socket => {
console.log(`A socket connection to the server has been made: ${socket.id}`)
socket.on('disconnect', () => {
console.log(`Connection ${socket.id} has left the building`)
})
})
}