robots.thoughtbot.com

Good article about window functions. Also note how they use a postgres feature called common table expressions.

jQuery doesn't store information about event listeners and data values with the element itself. This information is instead stored...

This guide shows how to create an AngularJS application that consumes more and more memory until, eventually, the browser process...

xaprb.com

The linked article explains how to get a database-wide lock without creating table rows: This article explains how I...

The easiest way to detect touch-capable browsers is to check for the presence of touch events. It is no...

coffeescript.org

The Javascript in operator does what Hash#has_key? does in Ruby: Return whether an object has a property.

makandra dev

TL;DR Block formatting contexts establish an isolating container. float and clear only apply to elements within such a container...

The CSS property z-index is not as global as you might think. Actually, it is scoped to a so...

To find a hash key by it's value, i.e. reverse lookup, one can use Hash#key. It's available...

If your angular app is not served on /, but on a different url (say /admin), links generated with ui-router...

makandra dev
github.com

Flickraw is a library to access flickr api in a simple way. It maps exactly the methods described in the...

makandra dev
github.com

SVG files are often much larger than necessary, containing comments, metadata, hidden elements etc. Optimize them with this tool.

markembling.info

Using uncountable resources is not recommended as it breaks Rails' magic, e.g. when using form_for. You'll always be...

If you get this error (probably because you want to load some modules): # modprobe xt_comment FATAL: Could not load...

I couldn't successfully execute a simple iptables command and got this error on an Ubuntu server: # /sbin/iptables -I INPUT...

Add gem 'database_cleaner' to your Gemfile. Then: Cucumber & Rails 3+ # features/support/database_cleaner.rb DatabaseCleaner.clean_with(:deletion) # clean once, now DatabaseCleaner.strategy = :transaction...

github.com

Then the "sorted" select should be sorted But the "unsorted" select should not be sorted

ImageMagick takes a string with several options when cropping an image. See the command line options for how to provide...

mjt.me.uk

Addressing is a fertile ground for incorrect assumptions, because everyone's used to dealing with addresses and 99% of the...

In the tradition of our PostgreSQL cheat sheet for MySQL lamers, here is a cheat sheet for Jasmine when you...

Here is a Javascript function reloadUsers() that fetches a HTML snippet from the server using AJAX and replaces the current...

When running Selenium features with parallel_tests, some browser-server interaction might take longer than usual and the impatient Capybara...

Angular 1.3+ has an alternative getter/setter pattern: You can bind ng-model to an accessor function. This is a function...

This is a problem when using Selenium with Firefox. We recommend using ChromeDriver for your Selenium tests. This setup allows...