pager-api
pager-api copied to clipboard
Add custom :page param
On a conversation with @ddnexus and @cseelus we were discussing about the possibility of having a a configuration option for the :page
param, rather than hard coding it to :page
.
This should work for the 3 supported pagination gems(Pagy, Kaminari, WillPaginate)
Here are some notes:
From a (resolved) Pagy issue:
The ability to add arbitrary params similar to will_paginates :params option or Kaminaris option with the same name would be helpful for a number of use cases:
[…] (not applicable for API pagination)
Passing search/form params around, when Pagy is used in combination with a search function
Passing in a controller/action name (see will_paginate or Kaminaris docs)