This gem adds the jQuery Mobile files to Rails' asset pipeline.
1.4.1 (gem 1.4.1)
Add this gem to your Gemfile:
Include jquery.mobile (or jquery.mobile.min) in your application.js manifest:
//= require jquery //= require jquery_ujs //= require jquery.mobile
And the same in your application.css manifest:
*= require_self *= require_tree . *= require jquery.mobile
I built this gem for using with the Mobylette gem, but it will work with your standalone application, or with any other gem that filters your mobile requests.
Please refer to jQuery Mobile's documentation for information on laying out your app and using all of the jQuery Mobile features: view.jquerymobile.com/1.4.1/dist/demos/
There is a very simple application inside test/dummy demonstrating basic usage of jQuery Mobile templating.
jQuery Mobile Rails' gem versions will align with jQuery Mobile's version numbering, with the most recent gem always providing the current stable release of jQuery Mobile.
To use an older version, please be sure to reference the proper gem version in your Gemfile. For example, to use 1.3.2:
gem "jquery_mobile_rails", "1.3.2"
Please make sure to follow these steps before submitting any pull requests:
Remove version number from the filenames
Place images in the subdirectory named 'jquery-mobile' (vendor/assets/images/jquery-mobile)
Run the rake task jquery_mobile_rails_css_fix. This will convert the css files to scss and ensure that the image references will properly use Rails' asset pipeline (by using image-url instead of url).
jQuery Mobile Page: jquerymobile.com/
Mobylette Gem: github.com/tscolari/mobylette
Mobile_fu Gem: github.com/brendanlim/mobile-fu