Just using will_paginate
and creating your own render works fine.
For bootstrap 4,throw this code into config/initializers/will_paginate.rb
Then, the code below into application_helper.rb
:
def will_paginate(collection_or_options = nil, options = {})
if collection_or_options.is_a? Hash
options, collection_or_options = collection_or_options, nil
end
unless options[:renderer]
options = options.merge renderer: WillPaginate::ActionView::BootstrapLinkRenderer
end
super *[collection_or_options, options].compact
end
And finally, call in the view like so:
nav aria-label="blah"
= will_paginate @items