how does gmail show new messages as they arrive

how does gmail make new messages appear in your browser as they arrive?

Javascrpt? -- H

The rails way to do this (update page when stuff happens at the server) is ActionCable
https://guides.rubyonrails.org/action_cable_overview.html

It runs on websockets and allows the server to push information to the browser. Your javascript on the page then needs to know what to do with that information.

It is typically slightly more complex to host than a ‘regular’ site as you probably need Redis running.

Rob, kudos to your insight and brevity to convert that question into a rails response.

Does it matter if my rails app is an api app or not?

Does it matter if my rails app is an api app or not?

Define (in terms of models and controllers) in what way they differ.

Colin