RailsCasts Pro episodes are now free!

Learn more or hide this

Applied Filters: markdown xRefactoring x
Presenters from Scratch
Episode #287 – Oct 03, 2011 – 122 comments

Presenters from Scratch

Clean up complex view logic with the help of presenters, and doing this from scratch gives you a lot of flexibility. Here I show not only how to create presenters, but how to test them using Test Unit and RSpec. (14 minutes)
Draper
Episode #286 – Oct 03, 2011 – 71 comments

Draper

Clean up complex view logic using Draper. This gem provides decorators (much like presenters) which bundles view logic in an object oriented fashion. In this episode I do a step-by-step refactoring of a complex template into a decorator. (12 minutes)