SVG files often contain redundant information, like editor metadata or hidden elements. When esbuild handles your static assets, you can...
There are several ways to run a single spec. I usually copy the spec file path with the line number...
The key to unlocking the full potential of LLMs in coding lies in crafting precise prompts. The main challenge is...
Ubuntu 24 added some guarding for Python packages which no longer allows installing applications through pip on system level. Instead...
Rails wraps your parameters into an interface called StrongParameters. In most cases, your form submits your data in a nested...
The new params.expect method in Rails 8 improves parameter filtering, addressing issues with malformed input and enhancing security. It provides...
Also see the list of IRB commands. Switching the context Changes the "default receiver" of expressions. Can be used to...
Your package-lock.json should always match and resolve all packages from your package.json. Coming from Yarn, I was looking for an...
In development, we store files using ActiveStorage's disk service. This means that stored files are served by your Rails...
In FactoryBot factories, Rails' file_fixture is not available by default. To enable it, include a support module from rspec...
Text fragments allow linking directly to a specific portion of text in a web document, without requiring the author to...
Git has the concept of hooks: bash scripts that are invoked at certain points in the Git lifecycle. One handy...
We recently migrated a Rails application from yarn to npm. We decided to go this step instead of upgrading to...
When using Rails credentials, you will edit the encrypted credentials for staging or production environments from time to time. To...
Slow test suites are a major pain point in projects, often due to RSpec and FactoryBot. Although minitest and fixtures...
If a Cucumber run deletes your application directory, an integration fail between Capybara and Capybara Screenshot may be the cause...
While the main goal always is to prevent long-running queries in the first place, automatic timeouts can serve as...
On our Ubuntu machines we have nautilus file manager with nautilus-extension-gnome-terminal installed. This adds an entry to...
Starting with ChromeDriver 127, if your application displays a beforeunload confirmation dialog, ChromeDriver will immediately close it. In consequence, any...
esbuild comes with a minifier that is good enough for most cases. If you're looking to squeeze out as...
With this command you can run all the spec files which have been edited or added in the current branch...
I recently stumbled over a quirk in the way Ruby handles local variables that I find somewhat dangerous. Consider:
I was recently asked to optimize the response time of a notoriously slow JSON API endpoint that was backed by...
While most Rails Apps are tied to at least one external REST API, machine-to-machine communication via GraphQL is...