metamaps--metamaps/app/assets/javascripts/realtime.js.coffee

6 lines
No EOL
207 B
CoffeeScript

window.app.realtime =
connect : () ->
window.app.socket = io.connect('http://metamaps.cc:5001');
window.app.socket.on 'connect', () ->
subscribeToRooms()
console.log('socket connected')