I’ve worked on a few apps in the past that had some cumbersome constraints in regards to the units of measurement. Models needed to store heat transfer or fluid dynamics properties in either english or SI units. This is can be a bit of a pain, so I...
ActiveSupport has a few great Ruby extensions that I just love. One of my favorites is try.
Try is a sneaky method for handling NoMethodErrors on NilClass. If you ever get stuck writing code like this:
name = user.name unless user.nil?
Consider...
When building new Rails projects, I often use Bootstrap because it lets me focus more on the business logic, rather than design. Almost everytime I start one of these projects, I forget how I did flash messages the last time, and have to look at a...