-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
allow querying connection metadata and then subsequent data in relayStylePagination #6935
Conversation
@anark: Thank you for submitting a pull request! Before we can merge it, you'll need to sign the Apollo Contributor License Agreement here: https://contribute.apollographql.com/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@anark Thanks for jumping into this code, and for adding tests! I agree with most of these changes, but I have one request for further consideration (below).
@benjamn Thanks for the feedback. I've adjusted the implementation, extended the test coverage to cover this, and updated from main. Please let me know what else this needs. |
I am dealing with an error that this PR could resolve here.
I am getting this when I do a subscribe to more on a field with relay style pagination policy and attempting to update the cache where |
…to query a connection without args
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM—thanks @anark!
Currently if you try to query relay connection metadata with no arguments
And then query for the edges/data
The cache will never have any todo items and both
data
anderror
returned by the cache will always be undefined.This attempts to fix this.
Checklist: