As seen on coderberry: http://coderberry.me/blog/2013/04/22/angularjs-on-rails-4-part-1/