Zen and the Art of the Controller
summary
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
chapters (12)
- 0:00Introduction
- 2:53Controller Bloat
- 4:05Example
- 5:10Basic Actions
- 6:12Ajax Actions
- 7:26Responsive UI
- 8:41Statistics
- 10:11Breaking it up
- 14:00Benefits
- 16:56Takeaways
- 23:47Design
- 26:51Conclusion
related talks
01h 43mProperly Factored MVC in Rails Applications
36mIn Relentless Pursuit of REST
41mOff the Tracks - Challenging the Rails Mindset
39mExploring Rails anti-patterns
31mIf it bleeds, it leads
01h 09mRails 3 ...and the real secret to high productivity
31mThe History of Rails in 10 Blog Posts
31mWhat Comes After MVC
