Tutorials
Adding Sidekiq Job Context to ActiveRecord Query Log Tags
Anyone that has worked with Rails for any significant amount of time probably knows that Rails performance tends to be tightly coupled to database query performance. For this reason, it’s extremely valuable to make friends with your local slow que...
How to reduce memory usage in Ruby – AbstractBrain Answers
The problem is related to Ruby threads and how memory allocation works at low-level. In many cases it’s not a memory leak, but just a memory bloat.Here’s two effective solution that we have used in production to reduce the memory usage:Reduce the ...
Using Watir to automate web browsers with Ruby | ScrapingBee
For years, it’s been possible to automate simple tasks on a computer when those tasks have been executed using the command line. This is known as scripting. A bigger challenge, however, is to control the browser since a GUI introduces a lot more v...
Dependent drop-down selects with Rails and Hotwire
This article will teach you how to create drop-down selects with Rails and Hotwire. I want to add country and state to the user. When users select a country, we want to fetch all states from this country and add to the states input-select. Let's s...
Using Svelte with optional TypeScript support in Rails 7 with Vite
In this tutorial we will take a look at how to integrate Svelte with optional TypeScript support in a Rails 7 project, with help of the Vite JS bundler.This tutorial is for a fresh created Rails 7 project, or an existing Rails app with vite-rails ...