I'm currently following the official Rails ActionCable guide.
It suggests creating a file for the subscriptions (App.cable.subscriptions.create{...}
) in app/assets/javascripts/cable/subscriptions/channelname.coffee
- but when I use the command rails g channel channelname methodname
it creates the corresponding file in app/assets/javascripts/channels/channelname.coffee
I've also been following this guide at nopio, that says it should be a JavaScript file - app/assets/javascripts/channels/channelname.js
I'm using Ruby 2.3.3 and Rails 5.0.2. Which place and which filetype is correct? Thanks for your help! :)