Using presenters and decorators to clean up your templates in Ruby on Rails (VIDEO)
When developing a web application, templates usually need to implement some logic, especially conditionals. I’m going to show you two patterns which are commonly used in web development with Ruby on Rails: presenters and decorators. They are meant to move template logic to dedicated classes, so templates look cleaner and more object oriented. http://davidmles.com/blog/presenters-decorators-rails/
Post a comment