FactoryBot allows to create traits from Enums since version 6.0.0 The automatic definition of traits for Active Record enum attributes...
# Basic HTML example # Javascript API (notable methods and properties) video = document.querySelector('video') video.play() video.pause() video.load() // Reset to the beginning and...
RubyMine has a HTTP Client that can be useful to test web APIs. Just create a .http scratch file an...
Select2 is a fantastic library for advanced dropdown boxes, but it depends on jQuery. Alternatives Tom Select
If you render markdown from user input, an attacker might be able to use this to inject javascript code into...
There is a reasonable simple way to move data between Redis servers: Simply temporarily configure the new server as a...
Speaker today is Henning Koch, Head of Development at makandra. This talk will be in German with English slides.
We use CarrierWave in many of our projects to store and serve files of various formats - mostly images. A common...
Using git fixup helps you to speed up appending changes further back in the git history of your feature branch...
In case you want to use pry with an older version of Ruby, you can try the following configurations.
You can install rubygems 3.0.8 (released on February 18, 2020) to keep all the Gem::Specification#rubyforge_project deprecation warnings...
When you have many changes, and you want to spread them across different commits, here is a way to stage...
The linked GitHub repository is a bit like our "dev" cards deck, but groomed from a single person (Josh Branchaud...
With puma you can have concurrent requests. There are two concepts on how Puma can handle two incoming requests: Workers...
Simplecov is a code coverage tool. This helps you to find out which parts of your application are not tested...
A recent patch level Ruby update caused troubles to some of us as applications started to complain about incompatible gem...
Embedding videos on a website is very easy, add a tag to your source code and it just works...
Because colors improve readability so much. On Ubuntu 18.04 you can install it with sudo apt install grc
Heads up: transparent is not a real color, but black with 0% opacity. In transparent gradients, this adds some gray...
To set a default Node version for new shells, use nvm alias default : nvm alias default 1.2.3
Or: How to avoid and refactor spaghetti code Please note that I tried to keep the examples small. The effects...
This is a personal post-mortem analysis of a project that was mainly build to provide a REST API to...
PostgreSQL and ActiveRecord have a good support for storing dynamic attributes (hashes) in columns of type JSONB. But sometimes you...
Debugging image color profiles is hard. You can't trust your eyes in this matter, as the image rendering depends...