Turbo (Native), Stimulus, and Strada articles, code, courses, and more. Plus exclusive insights into how I build Turbo Native apps. Delivered monthly.
My first RailsConf is officially over. 😢
But I had an amazing time meeting folks IRL for the first time! If we didn’t get to say hi then let me know and I’ll make sure we meet at the next conference.
All told, I learned a lot. My favorite technical talk was from Dave Copeland on why your app needs a service layer. Not necessarily service objects, but a spot where all of your business logic lives.
I took this to heart and have been slowly refactoring the railsdevs codebase to extract a service layer. I’m not 100% sure this will get merged in, but it is definitely fun to experiment with a new approach.
I know the word “service” gets a bad rep in the Rails world. But I think it’s worth exploring a new way to organize code every now and then.
Does your app have a service layer? Are you all in on a DSL/framework to help facilitate that? Or do you throw everything in Active Record models?
by Dr Nic @drnic
Following up on last month’s video, Dr. Nic published the next 2 parts of the tutorial on recreating Notion in Rails. These episodes cover inline editing and integrating Tip Tap for rich text editing.
by Cezar Halmagean (Mix & Go) @chalmagean
I’m really loving these 5 minute videos on Hotwire on the Mix & Go YouTube channel. This time we are walked through building a buddy list of sorts - a live-updating screen that shows who is currently online. Make sure to watch until the end as there is a gotcha for using this code in production.
by Roland Studer @RolandStuder
Turbo only provides 7 different Turbo Stream actions out of the box:
after. But what if you want your own custom action, like
redirect? Roland walks us through how to create your own custom Turbo Stream action with a Stimulus controller and a good ol’ helper.
by Thiago Araújo Silva @thiagoaraujos
Query Objects have been top of mind for me since adding filtering to railsdevs. They help keep all query-related business logic in a single model without ballooning the scope of your Active Record models. Here, Thiago walks through some steps to make your Query Objects easier to write and understand.
Leveraging popular pagination framework Pagy, Yaroslav and Phil progressively enhance a long list of items with Hotwire. What starts out as a button to load more results eventually becomes an infinitely scrolling list. There’s also a bonus section on building your own pagination without a third-party library.
by Guillaume @guillaumebriday
by Planet Argon @planetargon
The survey results are in! Every year Planet Argon runs the Ruby on Rails Community survey and this year they received over 2,500 responses. As always, they compare results to previous surveys with nice graphs and charts. I’m still diving in to all the results but there is a lot to learn here.
🙋♂️ Some personal updates
I took a hiatus from client work this month to focus on my side businesses. And boy have I been busy!
- Jumpstart Pro iOS got 11 new features and a script to get you started faster
- RailsDevs had 25+ PRs merged and still has 10+ open issues up for grabs
- RailsConf inspired a long list of things I want to do
- I drafted an outline of my Turbo Native workshop