Polling for New Records - Advanced

Episode #567 by Teacher's Avatar David Kimura

Summary

Continuing from the previous episode, we look at evolving the polling stimulus controller to handle pausing when the user navigates to a different tab, handle network errors, properly construct the URL and handle inserting new records differently. These small changes creates a much stronger polling mechanism.
rails stimulusjs polling 9:52

Chapters

  • Introduction (0:00)
  • Updating the stimulus controller (1:40)
  • Demo (6:34)
  • Final Thoughts (7:34)
Student & Teacher
$ 9 /mo

Valid School Email Required

Same Access as Pro

Subscribe Now
Pro Monthly
$ 19 /mo

Access to Pro Episodes

Invite to Slack Channel

Priority Suggestions

Ad Free

Subscribe Now
Pro Annual
$ 190 /yr

Access to Pro Episodes

Invite to Slack Channel

Priority Suggestions

Ad Free

Subscribe Now
Teams
$ 57 /mo

3 Users Minimum

$19.00 / user / month

Same Access as Pro

Subscribe to Teams