RSSAmplifier

Blog

Mateusz Białowąs

Product engineer at SportsKey from Poland. Sharing Ruby on Rails tips and tech insights. Follow my adventures in code and my career!

mateuszbialowas.comRSS feed ↗6 posts

Latest posts

Searching Owner-Specific Tags in Rails with ActsAsTaggableOn and Ransack

Recently, I needed to implement a search feature for tags that are attached to specific owners using the ⁠acts_as_taggable_on gem in a Rails project. Since we use Ransack for searching, I wanted to integrate both tools. However, the standard document...

How to create auto incrementing primary key with prefix in RoR application.

Recently, while experimenting with Stripe, I noticed that objects have IDs or identifiers with prefixes. Below, I've listed a few examples. You can find more in this gist: https://gist.github.com/fnky/76f533366f75cf75802c8052b577e2a5 PrefixDescri...

Utilizing RSpec Matchers for Order-Insensitive Array Comparisons

Introduction Ensuring stability and consistency in tests is very important. One key aspect of testing is the ability to avoid flaky tests, which are tests that do not pass each time they are run. Navigating Through Flaky Tests Sometimes, the ordering...

Handling Create and Update Operations with Turbo Streams in Rails 7 (rspec tests included)

TL;DR post searches_url, params: { search: invalid_attributes }, as: :turbo_stream I have recently implemented CRUD(Create, Read, Update, Delete) operations using Rails 7. There are multiple methodologies for creating and updating records. One such...

Testing Sidekiq in Ruby on Rails: A Comprehensive Guide

Introduction Sidekiq is a powerful tool for handling asynchronous jobs in Ruby. It can be easily integrated with Ruby on Rails applications to streamline background tasks. With Ruby on Rails, there are two main options for using Sidekiq: Integrate S...

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 sta...