-
Notifications
You must be signed in to change notification settings - Fork 64
Closed
Description
Offer a controller-level interface for automatically adding pagination links.
Possible interface
An ActionController instance method jsonapi_pagination(resources) that gets automatically called at render time with the rendered collection. The method would return a Hash or nil.
Example
class UsersController < ...
def jsonapi_pagination
{
first: ...,
last: ...,
...
}
end
def index
# ...
render jsonapi: users
end
endMetadata
Metadata
Assignees
Labels
No labels