Waves black and white pattern

How to Write a Clean Order By Case Query with Arel on Rails

You’re working on a feature and someone tells you that one of your models needs to be ordered based on some complicated rule. You realize you’ll need to write a complex order by query… Here’s how it usually goes: You think to yourself: “Should I write an order by case when statement? Maybe I’ll just add a little bit of SQL…" Two minutes later, you end up with a bunch of nested case when statements, subqueries, common table expressions, angry statements, shouting, and a whole lot of tears....

4 min · Thiago Araujo
Quickly Debug Ruby Gems with Pry, git bisect, and bundler

Guide: Quickly Debug a Ruby Gem with Pry and Git Bisect

Are you trying to debug a Ruby gem but not sure how? Here’s a quick way to debug any Ruby Project using Pry and Git Bisect. When triaging some open issues on Faker, an open-source Ruby gem, I came across Issue #2482. I was able to reproduce the problem. Turns out the bug was already fixed by this PR, but version v2.20.0 was released before that. I thought this would be a great opportunity to show you how I debugged this issue so you can learn some new tricks....

7 min · Thiago Araujo, Stefanni Brasil
Smart Ruby Developers Don't Ask for Advice

Smart Ruby Developers Don’t Ask for Advice. They Do This And Build A Reputation As a Result

If you could run a career quality tool to analyze your progress, would it say you’re moving in the right direction? What score would you get? Here’s the catch: how you think you’re doing and what your teammates think how you’re doing are not the same thing. Want to find out for sure whether you’re moving up the Engineering Ladder anytime soon or not? The only way is by asking for instructive feedback....

5 min · Stefanni Brasil, Thiago Araujo
No Idea How to Build a New Feature? 216+ Ruby on Rails Application Examples To Have as a Reference

216+ Ruby on Rails Open Source Applications You Can Use as a Reference

Not sure how to implement a new Ruby on Rails feature? A proper model, controller, migration? Or how to write a test for the code you’re writing? What if you could easily access a massive library of full-blown Ruby on Rails Applications used in the wild and have them as a reference? real-world-rails gives you a list of (173 apps + 43 engines) = 216 Rails Applications you can learn from 💣...

6 min · Thiago Araujo
Ruby Code Quality with Ernesto Tagwerker on the hexdevs podcast

Ruby Code Quality with Ernesto Tagwerker

Are you working on Ruby on Rails Applications that are constantly on fire, overwhelmed by technical debt? Instead of being a firefighter, what if you could be a happy programmer again and “Escape the tar pit”? Learn exactly how to measure tech debt and take the right steps to immediately improve code quality. Listen to our conversation with Ernesto Tagwerker (@etagwerker). Apple Podcasts | Spotify About our guest Ernesto Tagwerker is the founder & CTO at FastRuby....

44 min · Stefanni Brasil, Thiago Araujo
Just Enough Hotwire for Rails Developers with Chris Oliver Open Source Thursdays

Just Enough Hotwire with Chris Oliver

Chris Oliver is the founder of GoRails, JumpStart Rails, Hatchbox and RailsBytes. He is also one of the hosts of the Remote Ruby podcast. Chris showed us how to get started with Hotwire, how to inspect turbo streams. He also answered some questions from the audience, including how to migrate from Webpacker to jsbundling-rails, Websockets performance, and security. Do you want to know how Chris Oliver got so good at building products?...

2 min · Stefanni Brasil, Thiago Araujo
Green Leafed Trees Below Rainbow

How to Improve Code Quality on a Ruby on Rails Application

Does it take forever to ship even small features on the codebase you’re working on? Is the code hard to understand and maintain? Are projects always running over budget? Are you constantly sacrificing code quality and not paying down technical debt? When you change one feature, does another completely unrelated part of your app stop working? New bugs appear, even though tests never break? 🥵 Those are signs that you are suffering from working on a codebase with low code quality....

7 min · Stefanni Brasil, Thiago Araujo
Photo by Olha Ruskykh from Pexels

International Pricing for Ruby and Rails Books and Courses

Are you looking for courses, training, and resources to improve your Ruby and Ruby on Rails skills, but you are not being paid in US dollars? Most Ruby and Ruby on Rails books and courses are priced in US dollars. When you can’t afford them just because the country you live in has an undervalued currency compared to the dollar, it makes it difficult to invest in your education. There are many free options you probably already know about, and you’re already using them....

5 min · Stefanni Brasil, Thiago Araujo
Red lego blocks

How to Learn the Syntax of a Programming Language When You Know How to Code

Are you having a hard time picking up the syntax of a new programming language, even though you know how to code? You’re new to Ruby, and people say it’s an easy language, but you find the syntax difficult to understand. You know a bit of Javascript, Python, Java, or any other language. But Ruby seems like alien technology to you. By the end of this post, you’ll have a tool to help you transfer your knowledge of [INSERT PROGRAMMING LANGUAGE HERE] to Ruby....

4 min · Thiago Araujo
A bowl of spaghetti.

Learn Ruby on Rails Best Practices With One Exercise

You want to write smooth professional-looking code. You’re craving some squeaky-clean code. But all you have for lunch every day is a big bowl of legacy spaghetti code. You consider yourself a decent developer, but you’re never sure how to organize a project. How to name things. Where some piece of business logic should live. How can you become a Ruby on Rails expert if the code you read every day stinks?...

6 min · Thiago Araujo