tl;dr Since Rails 6+ you can use before? and after? to check if a date/time is before or after...
Sometimes the need arises for SSL in local development. We have guides for different webservers, this one is for puma...
These are the results of the "personal tech stack survey". I've included only the most popular mentions, maybe it...
To read the Rails session from a Rack middleware, use env['rack.session']. It's an ActionDispatch::Request::Session object.
When changing code in mailers, updating the corresponding mailer preview can be forgotten very easily. Mailer previews can be tested...
It might sometimes be useful to check whether your Rails application accesses the file system unnecessarily, for example if your...
Testing file download links in an end-to-end test can be painful, especially with Selenium. The attached download_helpers.rb provides...
You'll need openssl-3 or newer for servers running 22.04 Ruby version 3.1 uses by default the gem openssl...
When you need information about a gem (like version(s) or install path(s)), you can use the gem binary...
Redis.current will be removed without replacement in redis-rb 5.0. Version 4.6.0 adds deprecation warnings for Redis.current and Redis.current=: `Redis.current...
This are the steps I needed to do to add esbuild to an application that used the vanilla rails asset...
We use foreman to start all necessary processes for an application, which are declared in a Procfile. This is very...
Building application assets with esbuild is the new way to do it, and it's great, especially in combination with...
Sometimes you need to access a dev server running on localhost from another machine that is not part of the...
In my case [...] the catalog is an XML that contains all kinds of possible products, categories and vendors and it...
TL;DR When using Cache-Control on a Rails application, make sure the Vary: Accept header is set.
The Interactive Advertising Bureau (IAB) is a European marketing association which has introduced a standard how advertising can be served...
I sometimes had the issue that I received an error when starting an existing vagrant box with vagrant up:
A flaky test is a test that is often green, but sometimes red. It may only fail on some PCs...
If you want Sidekiq to be able to talk to Redis on staging and production servers, you need to add...
You want to use fields in your applications. However, your desktop users may encounter some weird quirks: Aside from allowing...
Event delegation is a pattern where a container element has a single event listener that handles events for all descendants...
Sometimes a link or input field has no visible label. E.g. a text field with a magnifying glass icon 🔎 and...
Besides their default styling properties, HTML elements have a semantic meaning. For example, an h1 tag is usually styled with...