The 90s are calling: they want their tables back. Unfortunately, you need them all for laying out your HTML emails...
Ruby has this handy block shortcut map(&:to_i) for map { |x| x.to_i }. However, it is limited to argument...
Whenever is a Ruby gem that provides a nicer syntax for writing and deploying cron jobs. Leading zeros are important...
To catch all possible exceptions from a network call, we need to rescue many error classes like this: rescue SocketError...
Here is how to model basic logic in media queries. AND With keyword and. # Target viewport widths between 500 and...
Since late 2015, all major browsers (still excluding Firefox) support pointing device media queries. These can be used to distinguish...
The method cookies is defined in the ActionController and should never be overwritten. Bad example class StaticPagesController < ApplicationController
When you need to store structured data (like Ruby hashes) in a single database column with ActiveRecord, a simple way...
Authentication is a special part of web applications. On the one hand, it usually is a crucial security mechanism restrict...
RSpec let's you chain a matcher with .or. The expectation will then pass if at least one matcher matches...
Browsers' printing methods usually don't print background colors. In most cases this is the desired behavior, because you don...
Just like Ruby Gems tag their version releases to the corresponding Git commit, it can be helpful to track production...
In medium-sized to large Rails applications, asset compilation can take several minutes. In order to speed up deployment, asset...
There is a kinda secret, yet well supported CSS feature called currentColor. It's like a special CSS variable that...
Create a user without password (recommended) Replace newuser with your desired username: mysql -uroot -p CREATE USER 'newuser'@'localhost' IDENTIFIED...
A matcher is a function that returns an object with a compare key. Usually it is registered with beforeEach...
TL;DR Append your locale keys with _html to have them marked as html_safe and translate them with = t...
CoffeeScript and JavaScript (ECMAScript) both have operators in and of. Each language use them for more than one purpose. There...
Using the JS fullscreen API is painful because all browers use different methods and events and you need to use...
When your application is running on a multi-server setup, application logs are stored per server (unless you choose a...
By default, Capistrano truncates server responses and places an ellipsis at the end of lines that are longer than your...
When your JavaScript bundle is so massive that you cannot load it all up front, I would recommend to load...
You know that you can use jQuery's text() to get an element's contents without any tags.
If your rails application is unable to send mails, it might be useful to debug your settings using the rails...