Code I like
Articles by Jorge Manrubia on Rails design techniques
and patterns. They feature code examples extracted
from 37signals apps.
Sign up to get posts via email,
or grab the RSS feed.
Maximalist positions are a thing in our industry. Take a technique, outline its drawbacks, extrapolate you can’t use it under any circumstance, and ban it forever. We are lucky that Rails embraces exactly the opposite mindset as one of its pillars.
Active Record restates the traditional question of how to separate persistence from domain logic: what if you don’t have to?
A common critique of Rails is that it encourages a poor separation of concerns. That when things get serious, you need an alternative that brings the missing pieces. We disagree.
We love concerns and have been using them for years in large codebases. Here we share some of the design principles we use.
Good code is a fractal: you observe the same qualities repeated at different levels of abstraction.