~/talk

Zen and the Art of the Controller

Talkat RailsConf 2016 · 2016-05-04..05-06· [ruby-on-rails, frontend-architecture]
slides:none on file

Argues controller bloat is controllable not inevitable and shows concrete refactors inside Rails using AJAX background jobs Devise and Active Record examples instead of vague advice the demo starts from a 350-line controller with ~18 actions then builds an AdsController that grows to 14 actions and splits into focused controllers like AdJobsController for background work an aggregate resource controller for audiences and a view-only controller for previews the result is easier debugging localized changes and fewer merge conflicts by using an API namespace when warranted

AI-written summary · about

  1. 0:00Introduction
  2. 2:53Controller Bloat
  3. 4:05Example
  4. 5:10Basic Actions
  5. 6:12Ajax Actions
  6. 7:26Responsive UI
  7. 8:41Statistics
  8. 10:11Breaking it up
  9. 14:00Benefits
  10. 16:56Takeaways
  11. 23:47Design
  12. 26:51Conclusion
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.