The name of your question is incorrect. Honestly, I think you probably just want to set up the will_paginate page list structure, which can be done in different ways.
So, in your case, the right way is to extend the visualization tool. For example, load from the initializer (via config / initializers) the following:
class CustomPaginationRenderer < WillPaginate::LinkRenderer def to_html
Then, for your application to use this renderer, add the following to the config / environment.rb file:
WillPaginate::ViewHelpers.pagination_options[:renderer] = 'CustomPaginationRenderer'
vise
source share