Guest User

Untitled

a guest
Dec 6th, 2018
150
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. a = io.of '/foo'
  2. b = io.of '/bar'
  3.  
  4. a.on 'connect', (socket) ->
  5.    
  6.     # this adds `socket` to room 'kitchen' in namespace 'foo'
  7.     socket.join 'kitchen'
  8.  
  9.     # how can I add `socket` to room 'kitchen' in namespace 'bar' instead?
Add Comment
Please, Sign In to add comment