No description, website, or topics provided.
Ruby JavaScript CSS
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
app/controllers
lib
spec
.gitignore
Gemfile
Gemfile.lock
Guardfile
MIT-LICENSE
README.rdoc
Rakefile
silly_mobilizer.gemspec

README.rdoc

SillyMobilizer

Easily manage mobile devices on your Ruby on Rails application.

Installation

Add the gem to your Gemfile

gem 'silly_mobilizer', git: 'git@github.com:siliconsalad/silly_mobilizer.git',  branch: 'develop'

Run the installer

rails g silly_mobilizer:install

If you want to enable the ability to force desktop version on mobile devices, create the following route

resource :device_type_selection, only: [:create, :destroy], controller: :device_type_selection

Finally to enable Silly Mobilizer add the following to your ApplicationController

include SillyMobilizer::MobileRequestsHandler

Usage

Whenever you want a view in your application to be rendered in mobile version, create it with mobile extension.

For example : index.mobile.erb

If the mobile version doesn't exist it automatically falls back to html version.

Workflow

If you want to test your work in a desktop simply add the browser of your choice in `mobile_identifiers.yml`. You can try with `- firefox`