Rails credentials are a way to store secrets in an encrypted YAML file. Usage is simple: each key in the...
It's possible to implement simple custom RuboCop cops with very little code. They work exactly the same like existing...
Sometimes we have to write code that behaves differently based on the version of a specific gem or the Ruby...
When Rails releases a new version of their gems, they also release a number of npm packages like @rails/activestorage or...
This card is a short summary on different ways of assigning multiple attributes to an instance of a class.
ActiveModel classes have a class method .human_attribute_name. This returns a human-readable form of the attribute: Person.human_attribute...
When you mocked method calls in RSpec, they are mocked until the end of a spec, or until you explicitly...
This card describes two variants, that add a more intuitive workflow when working with nested attributes in Rails + Unpoly.
This card describes different flavors for concatting HTML safe strings in a helper method in Rails. You might want to...
Debugging performance issues in your Rails app can be a tough challenge. To get more detailed insights consider using the...
Starting with Rails 7.1 the production logger is set to standard out. For applications running with opscomplete ensure to keep...
tl;dr Prefer request specs over end-to-end tests (Capybara) to joyfully test file downloads! Why? Testing file downloads
You can chain multiple Capybara matchers on the page or any element: expect(page) .to have_content('Example Course')
A common cause of non-accessible web pages are elements that were made interactive via JavaScript but cannot be focused...
The Web Animations API has great browser support, and you should be using it to animate DOM elements from JavaScript...
Today I stumbled across a pretty harmless-looking query in our application which turned out to be pretty harmful and...
Any form fields where users enter numbers should be an . Numeric inputs have several benefits over : On mobile or tablet...
tl;dr We recommend configuring Selenium's unhandled prompt behavior to "ignore". When running tests in a real browser, we...
A Rails script lives in lib/scripts and is run with bin/rails runner lib/scripts/.... They are a simple tool to perform...
Today I learned that you can animate HTML elements using the Web Animation API's method .animate(keyframes, options) (which...
Multiply by 1x the unit: $number = 13 $length = $number * 1px // => 13px Removing a unit
RubyMine has a collaboration feature called "Code With Me". Using it, you can invite someone into your local editor to...
You can ignore certain commits when using git blame with the --ignore-revs-file option. This is handy to ignore...
Getting an entire test suite green can be a tedious task which involves frequent switches between the CLI that is...