ViewComponents in the Real World
summary
Claims that ViewComponent makes view code reusable testable and encapsulated get concrete: Rails 6.1 support for renderable objects, a custom ERB annotator, a System-test conversion shim, and a command-line viewfinder tool for tracing templates. Results include 100x faster tests versus controllers, a 15× growth in components, automated linters that block regressions, an N+1 fix saving ~100ms, and CI matrix builds that combine coverage to enforce 100% coverage. Watch for code, tools, numbers, and what actually changed.
AI-written summary · about
chapters (20)
- 0:00ViewComponents at GitHub
- 2:36Design system at scale
- 5:00Identifying templates with HTML
- 7:06Controller to system tests
- 9:58Tracking template usage
- 16:20Missing abstraction in Rails
- 17:44ViewComponents in Rails
- 19:57Consistency with ViewComponents
- 21:00Performance in views
- 23:08Mailers with ViewComponents
- 25:14Slots for complex layouts
- 29:05Storybook for components
- 30:29Rollout strategies
- 33:16Documenting ViewComponents
- 36:10Linters and RuboCop
- 37:56Team rollout experience
- 40:06Open sourcing lessons
- 42:58Rails conventions
- 45:05Rails and Ruby innovations
- 47:52Q&A








