Ruby + Rails : Distilled
banner
distilled.skillstopractice.com
Ruby + Rails : Distilled
@distilled.skillstopractice.com
A collection of posts of interest to Ruby and Rails developers.

Hand-picked, high signal, always on topic.

Maintained by @skillstopractice.com

Also available as a feed:
https://bsky.app/profile/did:plc:ip3trmvdbnlm4g7cdc5xs7ub/feed/aaaf5jle4pb7e
Pinned
Ruby + Rails : Distilled is moving to Mastodon.

Just getting set up over there but you'll find the account here:

ruby.social/@distilled

I will set up bridging when I can, not sure if I will do crossposting though.

If you're set up with @ap.brid.gy here I can still share your posts that way.
Reposted by Ruby + Rails : Distilled
I just signed the open letter to the Rails Core team, after hesitating for a long time about whether that was the right choice for me.

I know and like several Rails core members, as well as several Basecamp employees. I understand the squeeze that can happen when speaking out individually only […]
Original post on mastodon.social
mastodon.social
September 28, 2025 at 4:48 PM
Reposted by Ruby + Rails : Distilled
So the way I read this is a sponsor forced this action by Ruby Central.

If that sponsor was Shopify, then in effect, this confirms that a company that DHH is a board member of forced this action.

If not, who was responsible for this then?

This is a very […]

[Original post on mastodon.social]
September 21, 2025 at 11:17 PM
Ruby + Rails : Distilled is moving to Mastodon.

Just getting set up over there but you'll find the account here:

ruby.social/@distilled

I will set up bridging when I can, not sure if I will do crossposting though.

If you're set up with @ap.brid.gy here I can still share your posts that way.
May 21, 2025 at 11:55 AM
Reposted by Ruby + Rails : Distilled
I'm leaving Bluesky effective immediately and this is the reason why.

I'll post when I get Mastodon set up + an RSS feed + newsletter.
why.bsky.team Why @why.bsky.team · May 19
If you have problems with us as a company making revenue, then i've got some bad news.
May 19, 2025 at 9:41 PM
Reposted by Ruby + Rails : Distilled
The penultimate part of SOLID: the Interface Segregation Principle.
SOLID: Interface Segregation Principle (ISP)
The Interface Segregation Principle is about designing thin, cruft-free interfaces which results in reduced coupling.
schembri.me
May 17, 2025 at 10:14 AM
Reposted by Ruby + Rails : Distilled
ViewComponents reduce bloat, simplify data, and create reusable frontend styling. Despite these benefits, they're often under-utilized in the Rails community. I've written a blog post refactoring a real-world example into isolated ViewComponents.

joshfrankel.me/blog/viewcom...

#ruby #rubyonrails
ViewComponents, the Missing View Layer for Rails
If you’ve worked with Rails for any measure of time, then you know that Rails’ Views can quickly get out of hand. Between Helpers, instance variables, and inline logic, they quickly become bloated and...
joshfrankel.me
May 15, 2025 at 12:56 PM
Reposted by Ruby + Rails : Distilled
You might get less performance from using `.excluding` than `.where.not` and here's why.

dcyoung.dev/shorts/how-e...

#RubyOnRails #WebDevelopment
🎓 How .excluding works in Rails
Rails provides a convenient .excluding method for identifying a group of items while omitting another set.
dcyoung.dev
May 16, 2025 at 11:05 AM
Reposted by Ruby + Rails : Distilled
How do you manage error classes in your app?

- Granular — Domain::Specific::NotFoundError
- Generic/Reusable — Error::NotFound
- Not — StandardError/raise 'x'

Personally, I create my own error classes so I can see what's wrong at a glance, even if it means catching existing ones.

#RubyLang
May 16, 2025 at 9:35 AM
Already several good RSS feeds in the thread.

Keep them coming! Discoverability is hard these days and RSS was one of those lovely tools that deserves a comeback.
If you've got a blog where you (at least sometimes) write Ruby-related posts, please reply with a link to your RSS feed below.

I am going to try to start keeping an eye on those as well and sharing interesting stuff I find from time to time.
May 16, 2025 at 1:10 PM
If you've got a blog where you (at least sometimes) write Ruby-related posts, please reply with a link to your RSS feed below.

I am going to try to start keeping an eye on those as well and sharing interesting stuff I find from time to time.
May 15, 2025 at 11:48 PM
Reposted by Ruby + Rails : Distilled
What do you love about programming in #ruby?
May 15, 2025 at 3:04 PM
Reposted by Ruby + Rails : Distilled
Don't want to expose a class' initializer in Ruby? Making it private is easy!

Just use `private_class_method :new`.

This conveys intent that your class is not designed to be initialized from outside — perfect when you want to use the factory pattern.
May 15, 2025 at 7:09 PM
Reposted by Ruby + Rails : Distilled
How to automatically trigger a file download with Turbo?

The user triggers the creation of a file. That file is created using a background job. I could update the view using Turbo Streams (e.g. render a 'Download Now' button). But I'd like download to automatically start 🤔

#rubyonrails
May 15, 2025 at 1:29 PM
Reposted by Ruby + Rails : Distilled
Namespaces 101

During the last days I have done an immersion into namespaces, the new big feature that is coming in Ruby.

Here's a digested mental model for you all.

gist.github.com/fxn/86ad8584...
namespaces.md
GitHub Gist: instantly share code, notes, and snippets.
gist.github.com
May 15, 2025 at 12:03 PM
Reposted by Ruby + Rails : Distilled
Incredibly common Rails perf anti-pattern:

Rails.cache.fetch([complicated,cache,key], expires_in: random_interval) do
dog_of_a_SQL_query
end

Cache hitrate: 10% (if anyone even knows what it is)
May 14, 2025 at 5:04 PM
Reposted by Ruby + Rails : Distilled
Quick reminder that you should be using Jemalloc 👀

#rubyonrails #ruby
May 14, 2025 at 1:28 PM
Reposted by Ruby + Rails : Distilled
Reposted by Ruby + Rails : Distilled
hey #RubyLang folks - our tests against Ruby head in sentry-ruby started failing yesterday with:

LoadError: cannot load such file -- cgi/cookie

I'm disabling ruby head version in our CI matrix for the time being but maybe there's a fix somewhere?
May 14, 2025 at 7:19 AM
Reposted by Ruby + Rails : Distilled
Your periodic reminder that consolidating a wobbly design is worse than a waste of time, it interferes with further improvement. Sometimes the best thing is put all the elements in one pile until the fault lines become clear. #AugmentedCoding #GeniesDesignBadly
May 14, 2025 at 2:52 AM
Reposted by Ruby + Rails : Distilled
What's the best host for running a Ruby application, that stores files on the server, and runs sqlite as the database, on the server?
May 13, 2025 at 4:54 PM
Reposted by Ruby + Rails : Distilled
Having setters that appear to be at the instance level apply at the class level is something that (for me) definitely would be against the Principle of Least Surprise.

An easy way to define class level accessors is nice but hard to see the use case for the instance level behavior.
May 13, 2025 at 2:02 PM
Reposted by Ruby + Rails : Distilled
TIL about the ActiveSupport `mattr_accessor` method. It defines both class and instance accessors for class attributes.

Handy little shortcut! 🔧

#ruby #rubyonrails
May 13, 2025 at 1:28 PM
Reposted by Ruby + Rails : Distilled
Absolutely love this. Have figured out a bunch of this stuff from first principles over the last 2 years, but still loads of goodies in here.

plainvanillaweb.com/index.html
Plain Vanilla
An explainer for doing web development using only vanilla techniques.
plainvanillaweb.com
May 12, 2025 at 8:02 AM