aboutsummaryrefslogtreecommitdiffstats
path: root/actioncable/lib/rails/generators/channel/USAGE
blob: bb5dd7e2dbcb9bb236dbd6307f05c1b9b739bc6a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
Description:
============
    Stubs out a new cable channel for the server (in Ruby) and client (in JavaScript).
    Pass the channel name, either CamelCased or under_scored, and an optional list of channel actions as arguments.

Example:
========
    rails generate channel Chat speak

    creates a Chat channel class, test and JavaScript asset:
        Channel:    app/channels/chat_channel.rb
        Test:       test/channels/chat_channel_test.rb
        Assets:     app/javascript/channels/chat_channel.js