All threads / Realtime Group Chat with Rails [Revised] - Part 2 Discussion

Ask A Question

Notifications

You’re not receiving notifications from this thread.

Realtime Group Chat with Rails [Revised] - Part 2 Discussion

Nice video Chris.

I did something similar on a project a while ago but not with the elegant stimulus js solution.

Something that I am wondering about Websockets. In terms of edges cases or pitfalls that one could fall into pretty easily, what are some good ones to look out for?

Reply

Thanks Chris! I'm hoping for another episode in the series for direct messages.

Direct messages and group messages would be a dream

Reply

Great stuff Chris, Stimulus is really growing on me. Omakase for the win!

Reply

Hi Chris,
How can we identify our messages and their messages for user interface stuff?

Reply

Hi Chris,

I'm not sure if anyone has found this same issue, but I can't get the action to clear the input to fire in the stimulus controller. I'm using Rails 6.1.3, although I don't know if that makes a different. It's almost as if the ajax:success event is never fired or never detected. I can get an action to work on the submit event for the form, but none of the ajax events appear to work.

I just found out. It seems I needed to add local: false to the form. Now it works. Unrelated, I keep getting warnings about data-target-channel being deprecated in favor of data-channel-target.

Reply

Hi Chris,
How can I make this happen with rails 5.2?

Reply
Join the discussion

Want to stay up-to-date with Ruby on Rails?

Join 53,130+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.

    logo Created with Sketch.

    Ruby on Rails tutorials, guides, and screencasts for web developers learning Ruby, Rails, Javascript, Turbolinks, Stimulus.js, Vue.js, and more. Icons by Icons8

    © 2021 GoRails, LLC. All rights reserved.