Below is a strict, but still workable Content Security Policy for your Ruby on Rails project. Use this CSP if...
When working with file uploads, we sometimes need to process intrinsic properties like the page count or page dimensions of...
If you need to implement newsletter sending, rapidmail is a solid option. Support is very fast, friendly and helpful, and...
Postgres supports multiple built-in range datatypes: int4range int8range numrange tsrange (range with timestamp without timezone) tstzrange (range with timestamp...
You may remember to use the || operator with caution to set defaults. We'll see that && and other conditionals come...
In rare circumstances, you want to use a websites full domain (say https://mywebsite.com) while testing in dev mode. This...
TypeScript basically uses structural typing, which is conceptually quite similar to duck typing, but with static compile-time type checking...
In some projects we have issues with flaky tests. The best default is to fix them all. But in some...
Leaving old unused DB columns around after a migration is confusing for other developers. However, dropping columns too eagerly might...
I use the Gemini web chat interface quite extensively. One thing that is tedious is giving it all the context...
Knapsack allows you to rerun a specific job locally. This is helpful to run specs in the exactly same order...
If your rubocop run fails with a stack like rubocop-1.61.0/lib/rubocop/server/socket_reader.rb:36:in `ensure in read!': undefined method `string...
Event listeners are called in the order of their registration: button.addEventListener('click', () => console.log("I run first")) button.addEventListener('click', () => console.log("I...
I have a form with a dynamic number of fields. Submitting it worked fine until I tried out a very...
The :test adapter doesn't respect limits_concurrency configuration. Switch to :solid_queue adapter in your test to verify blocking...
If you use the selenium-webdriver gem, it will sneakily phone home once every hour whenever you run a browser...
Most of our CI pipelines don't use the --retry flag for Cucumber and instead build their own retry via...
Short reference on how to quickly debug the vanilla Rails job adapters. Queue Adapters by Environment Environment Adapter
I recently had to update a few selective npm libraries in a project that uses pnpm to apply a CVE...
Sometimes you have a maintenance script where you want to iterate over all ActiveRecord models. Rails provides this out of...
When creating a database table for a join model without further importance, you can use Rails' create_join_table:
When you query the browser for DOM elements, there are some footguns you should know about. Some lists are synchronized...
A simple web tool for generating lighter (tints) and darker (shades) versions of any HEX color value. Tip
Finding changes When you're looking for a specific change in Git, there are multiple axes you can choose: