Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to Implement GraphQLQueryPager in Apollo iOS for Pagination? #3406

Closed
adha8911 opened this issue Jul 10, 2024 · 2 comments
Closed

How to Implement GraphQLQueryPager in Apollo iOS for Pagination? #3406

adha8911 opened this issue Jul 10, 2024 · 2 comments
Labels
question Issues that have a question which should be addressed

Comments

@adha8911
Copy link

Question

I'm currently working on implementing pagination in my iOS application using Apollo for GraphQL queries. I came across the Apollo iOS documentation on pagination, which mentions a GraphQLQueryPager for handling pagination. However, I am unable to find any reference or implementation details about GraphQLQueryPager in the Apollo iOS SDK.

Could someone provide guidance or examples on how to properly implement GraphQLQueryPager for pagination in Apollo iOS? Specifically, I'm looking for:

An example of how to set up and use GraphQLQueryPager for paginating through a list of items. Any required configurations or setup steps that I might be missing. Alternative approaches to handle pagination if GraphQLQueryPager is no longer supported or available.

https://www.apollographql.com/docs/ios/pagination/introduction#using-a-graphqlquerypager

Here are some details about my setup:

I am using the latest version of Apollo iOS via Swift Package Manager (SPM).
I have imported the Apollo package successfully in my project.

@adha8911 adha8911 added the question Issues that have a question which should be addressed label Jul 10, 2024
@BobaFetters
Copy link
Member

@adha8911 The documentation you found is the correct although it looks like it doesn't mention that the pagination feature is its own supplemental package to apollo-ios, you will need to include the apollo-ios-pagination package via SPM as well to get access to the GraphQLQueryPager, once you've done that the documentation page you linked (and the few others associated to pagination) should give you the info you need to get up and running.

I will make a small update to the documentation to make sure to callout that pagination is its own package.

Copy link
Contributor

Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo iOS usage and allow us to serve you better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Issues that have a question which should be addressed
Projects
None yet
Development

No branches or pull requests

2 participants