Tutorials


For organizing Rails projects, domain objects are good and service objects are bad
In the early stages of a Rails project’s life, the pattern of putting all the model code into objects that inherit from Active Record works out pretty nicely. Each model object gets its own database table, some validations, some associations, and ...

Getting Started with the Sorbet Type Checker in Rails
At Monolist, we’re building a command center for engineers. We integrate with the APIs of all the tools engineers commonly use to aggregate their tasks in one place. For example, our customers trust us to pull in their Jira issues, Github pull req...


Efficient algorithm to check dates overlap – Rails Guides
Picture this. A real estate site’s guest wants to book a hotel for specific dates. The system should check whether these dates are available, i.e. if they are not overlapping with some other existing booking. Let’s say, software engineers have wri...





Tutorial - Use transactions to extract your Rails controller
When your Rails app needs to handle multiple steps, your controllers' methods can become a mess. Don't despair, though. You can delegate sequential steps to business transactions and Marie-Kondo those messy controllers. I'll show you how.Let's kee...