DEV Community

Discussion on: GraphQL pagination with DynamoDB - Putting it together

Collapse
 
andyrichardsonn profile image
Andy Richardson

Hey Pedro, thanks for the comment!

Feel free to use all/any of the code examples 👍 The project you have looks interesting and I'll definitely keep an eye on it!

I think one of the larger challenges with encapsulating pagination into a library is how much variance needs to be considered.

For example, there is some required domain/schema knowledge to be able to construct cursors, users might require (or want to avoid) calculating the hasPreviousPage value, and I'm sure there are a large number of additional edge cases (post-fetch filtering, etc).

It looks like you've already made a tonne of headway so maybe this is/could be a solved problem for those who have less exotic needs and are happy working within the constraints of a library 🚀