Skip to content

Integrates the Twitter Bootstrap pagination component with will_paginate

License

Notifications You must be signed in to change notification settings

HeyPublisher/will_paginate-bootstrap

 
 

Repository files navigation

will_paginate-bootstrap


Minimal Updates

The original author of this gem is no longer maintaining it. This version of the gem is being maintained solely for the use within the HeyPublisher appliction. If you have feature requests, it may take us a while to get to them.


Bootstrap Pagination Component

This gem integrates the Twitter Bootstrap pagination component with the will_paginate pagination gem.

Just like will_paginate, Rails and Sinatra are supported.

Install

  • gem install will_paginate-bootstrap, or
  • For projects using Bundler, add gem 'will_paginate-bootstrap' to your Gemfile (and then run bundle install).

Usage

Rails

  1. Load the Bootstrap CSS in your template.
  2. In your view, use the renderer: BootstrapPagination::Rails option with the will_paginate helper, for example:
<%= will_paginate @collection, renderer: BootstrapPagination::Rails %>

Sinatra

  1. Load the Bootstrap CSS in your template.
  2. require "will_paginate-bootstrap" in your Sinatra app.
  3. In your view, use the renderer: BootstrapPagination::Sinatra option with the will_paginate helper, for example:
<%= will_paginate @collection, renderer: BootstrapPagination::Sinatra %>

Compatibility

Starting at version 1.0, this gem no longer supports Bootstrap 2.

Ruby >= 1.9.2
will_paginate >= 3.0.3
Twitter Bootstrap >= 3.0.0

Bootstrap 2 users can use version 0.2.5 of the gem which was the last version to offer Bootstrap 2 support.

About

Integrates the Twitter Bootstrap pagination component with will_paginate

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Ruby 100.0%