Class: CursorChatChannel
- Inherits:
-
ApplicationCable::Channel
- Object
- ActionCable::Channel::Base
- ApplicationCable::Channel
- CursorChatChannel
- Defined in:
- app/channels/cursor_chat_channel.rb
Instance Method Summary collapse
Instance Method Details
#receive(data) ⇒ Object
6 7 8 |
# File 'app/channels/cursor_chat_channel.rb', line 6 def receive(data) ActionCable.server.broadcast(params[:id], data) end |
#subscribed ⇒ Object
2 3 4 |
# File 'app/channels/cursor_chat_channel.rb', line 2 def subscribed stream_from params[:id] end |