rake stats # => LOC per controllers, models, helpers; code ratios, and more rake notes # => collects TODO, FIXME and...
Eduardo Russo was tired of complex favicon creation and created his own favicon generator. It's really easy and allows...
I had to deal with JavaScript Undefined Error while accessing a specific CKEditor instance to fill in text. Ensure everything...
Ask before leaving an unsaved CKEditor Vanilla JavaScript way, but removes any other onbeforeunload handlers: $(function(){ document.body.onbeforeunload = function() { for(editorName...
"Redis Desktop Manager (aka RDM)— is a cross-platform open source Redis DB management tool (i.e. Admin GUI). Redis Desktop...
At TaskRabbit, we have gone through a few iterations on how we make our app(s). In the beginning, there...
If you have a text that is edited by WSYIWYG-Editor but want some length checking nevertheless, you need to...
Sometimes you want to strip a text of every special char. If you use \W, the result might not be...
After I upgraded to Mac OS X Mavericks, I regularly got this error message when running Cucumber features with Selenium...
Warning: Because of (unclear) rounding issues and missing decimal places (see examples below), do NOT use this when dealing with...
Alternative approach to form models.
Colorizes code in LibreOffice Writer. Note that you need to create a paragraph style _code for this to work.
Great slide deck about various forms of refactorings.
We have released Modularity 2. It has many incompatible changes. See below for a script to migrate your applications automatically...
When you do something like this in your code: def var_value @var ||= some_expensive_calculation end
Icons Sizes for Windows, MacOS X, iOS, Android and Linux. It's a mess!
If you have a FooController and also have a layout app/views/layouts/foo.html, Rails will use this without being told so.
TLDR: This card explains which threads and processes interact with each other when you run a Selenium test with Capybara...
tl;dr: Using has_many associations with a :through option can lead to lost or duplicate records. You should avoid...
We've since created ActiveType which has a restricted subset of Virtus' features. It might be enough for your needs...
In Ruby, classes and modules are called constants. This card explains how Ruby resolves the meaning of a constant.
CarrierWave attachments have two distinct methods #url and #path which appear to behave the same: document.file.url # => /storage/documents/4/letter.doc document.file.path # => /storage/documents/4/letter.doc
Assert rmagick provision ... Gemfile gem 'rmagick', '2.13.2' # at this moment the latest stable version config/initializer/carrierwave.rb require 'carrierwave/processing/rmagick' ... and define a...
Goal Within before_* Within after_* Cancel later callbacks throw :abort throw :abort Rollback the transaction throw :abort raise ActiveRecord::Rollback...