Skip to content

How can I paginate included resources? #969

Answered by sliverc
esmail asked this question in Q&A
Discussion options

You must be logged in to vote

It is currently only possible to do pagination on top level resources in DJA but not the included collection.

The specification states any pagination to be optional so if we wanted this to be added as a feature in DJA we should discuss actual use cases which such pagination would cover and then how to technically implement it.

A server MAY choose to limit the number of resources returned in a response to a subset (“page”) of the whole set available.

My first thought is that such a pagination is fairly limited as included collections can be a collection of different types. I haven't tested this but you could have related urls links which then allow you to paginate. This way your client c…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@esmail
Comment options

@esmail
Comment options

@sliverc
Comment options

Answer selected by esmail
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants