Session

Custom Rails Helpers: Keeping Your Views DRY

Glenn Vanderburg, Independent Consultant

Date: Saturday, May 19
Time: 10:45am - 11:35am
Location: Oregon Ballroom 203

Rails generally makes it easy to keep your code well designed and properly factored. Even so, many Rails projects still have duplicated code and misplaced logic in their views. This talk explains how to keep your views clean and DRY by writing your own helpers. We'll cover the basic concepts, including writing helpers to generate HTML, JavaScript, and a mixture of the two. We'll also cover how to follow the principle of least surprise, making your helpers work like the built-ins so they'll be easy for other team members to pick up and use.
Conference News and Coverage