RSpec >= 3.3 added aggregate_failures, which allows multiple failures in an example and list them all, rather than aborting on...
If you have a PostgreSQL dump in the custom format you can can view the text format dump (plain SQL...
For searching in large database tables we usually use PostgreSQL's fulltext search capabilities. While this works reasonably well for...
Spammers have started abusing other application to send their spam. This works like this: The application has some form that...
When building an application that sends e-mails to users, you want to avoid those e-mails from being classified...
The rendered font often depends on the local font your system provides, therefore you often find a rule like below...
If your Rubymine does not recognize a file type correctly although you have entered the unmistakeable file extension like material_orders_controller.rb...
Mobile Chrome and Safari support the "web share API" which allow you to use the native share functionality of an...
In this example we assume that not only the storage gem changes but also the file structure on disc.
If you want to fill in textareas with multiple lines of text (containing line breaks / new lines) you can use...
Rails defines a #truncate helper as well as a method String#truncate. = truncate("my string", length: 5) = "my string".truncate...
The 90s are calling: they want their tables back. Unfortunately, you need them all for laying out your HTML emails...
Since late 2015, all major browsers (still excluding Firefox) support pointing device media queries. These can be used to distinguish...
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...
There is a kinda secret, yet well supported CSS feature called currentColor. It's like a special CSS variable that...
TL;DR Append your locale keys with _html to have them marked as html_safe and translate them with = t...
When your application is running on a multi-server setup, application logs are stored per server (unless you choose a...
You know that you can use jQuery's text() to get an element's contents without any tags.
For outputting a given String in HTML, you mostly want to replace line breaks with or tags.
Lets say we have a user with a contract whereas contract is a mounted carrierwave file. Now we want to...
When you need test images, instead of using services like lorempixel or placehold.it you may generate test images yourself.
When you find yourself constantly ignoring a RubyMine warning, you can simple disable that warning and de-clutter your editor...
On your local system that only hosts non-critical development data and only you have access to, you can store...