Unobtrusive jQuery with Rails 3
Following versions of jQuery are supported:
Add this line to your Gemfile:
Run this command:
$ rails generate jquery:install # --ui if you want jQuery UI
Step 3 (optional)
$ gem install bundler $ bundle install
$ bundle exec ruby test/server.rb
Visit localhost:4567 and all the tests should pass.
At the top of the page you will see links to jQuery 1.4.1 and 1.4.2 . By clicking on those links you will be executing the tests against the clicked version of jquery. By default test uses jQuery 1.4.2 .