Capybara has a variety of finder methods like find_button to help you look up DOM elements. There are also...
Maintaining larger projects makes it more difficult to balance refactoring and upgrade tasks according to its actual value. Consider to...
Let's say we have posts with an attribute title that is mandatory. Our example feature request is to tag...
SASS has an @extend keyword to inherit styles. .alert color: red &.-framed border: 1px solid red padding: 5px &.-homepage
Container queries enable you to apply styles to an element based on the size of the element's container. If...
This is a checklist I use to work on issues. For this purpose I extracted several cards related to the...
Rails partials have a lot of "hidden" features and this card describes some non-obvious usages of Rails Partials.
Not all email clients support external images in all situations, e.g. an image within a link. In some cases, a...
After upgrading to Rails 6.1.7.2 one of our apps printed a wall of warnings while booting: /var/www/app/shared/bundle/ruby/2.6.0/gems/net-protocol-0.2.1/lib/net/protocol.rb:68: warning: already...
The linked article found a simple way to rewrite legacy git aliases to make them work with differently named default...
I recently enjoyed debugging a Cucumber step that tried to be retryable using a patiently block: Then /^"([^"]*)" should( not)? be...
Timecop is a great gem to set the current time in tests. However, it is easy to introduce flakyness to...
In a Jasmine spec you want to spy on a function that is imported by the code under test. This...
The cards editor has a feature "Cite other card" to create links to other cards in the same deck as...
You have some SVG files you want to use as icons on your website. How would you embed them?
Unpoly's [up-observe], [up-autosubmit] and [up-validate] as well as their programmatic variants up.observe() and up.autosubmit...
tl;dr git checkout is the swiss army of git commands. If you prefer a semantically more meaningful command for...
One rule of thumb I try to follow in capybara tests is using capybara matchers and not plain rspec matchers...
tl;dr git checkout is the swiss army of git commands. If you prefer a semantically more meaningful command for...
When you build a JSON API you need to come up with a style to represent attributes, pagination, errors or...
Resolve @{-1} to actual branch name. (Happens when merging "-".)
Greg Molnar has written a neat article about creating a single-file Rails app. This is not meant for production...
When working with feature branches, stale branches pile up over time. It's best to remove them right after merge...
You can use the code below to check whether the browser can make connections to the current site: await isOnline...