-
Notifications
You must be signed in to change notification settings - Fork 657
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
Pagination: merge nodes
field in addition to edges
#5735
Comments
Is there? (Or can we add?) an existing pull request or proposal to add this to the Relay specification? Would be rad to add this but having some proposal before doing the implementation would be even rad-er! |
I also hope that Nodes will be reflected in the Relay specification. In the Relay specification, Edge cursors are not used, but even so, this is in the Note format and does not fundamentally address the issue. Additionally, the terms "Relay Classic", "Relay Legacy", and "Relay Modern" appear in the Relay specification, but we do not understand what each of them refers to. |
@sonatard do you want to open an issue in the Relay repo and we can follow up with the Relay team to clarify the terms and explore the possible addition of |
Thank you for the suggestion. I plan to open two issues. |
Create a following issue And I had actually created an issue about nodes in the past. I had forgotten about it until today. |
Good find! upvoted! |
Closing now as this is available in the incubating caching artifact. Don't hesitate to open tickets for comments/issues with this. |
Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo Kotlin usage and allow us to serve you better. |
Currently it is possible to configure the (incubating) pagination system to handle Relay-style pagination by using
@TypePolicy(connectionFields: ...)
andConnectionFieldMerger
.This will automatically merge the lists in
edges
into a single record, allowing the app code to watch it and update the UI.In addition to the
edges
field, it is common for schemas to also have anodes
field (e.g. the GitHub and Shopify schemas), which simplifies a bit the usage of the API.ConnectionFieldMerger
could handle this by mergingnodes
in addition toedges
, if present.Original question about this here.
The text was updated successfully, but these errors were encountered: