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

allow nested defers at the same level #4002

Merged
merged 1 commit into from
Mar 20, 2024
Merged

Conversation

yaacovCR
Copy link
Contributor

Implements Option A from graphql/defer-stream-wg#80

@yaacovCR yaacovCR added the PR: feature 🚀 requires increase of "minor" version number label Dec 22, 2023
Copy link

netlify bot commented Dec 22, 2023

Deploy Preview for compassionate-pike-271cb3 ready!

Name Link
🔨 Latest commit bf20902
🔍 Latest deploy log https://app.netlify.com/sites/compassionate-pike-271cb3/deploys/65f9f289d20bb5000870dfe8
😎 Deploy Preview https://deploy-preview-4002--compassionate-pike-271cb3.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

Hi @yaacovCR, I'm @github-actions bot happy to help you with this PR 👋

Supported commands

Please post this commands in separate comments and only one per comment:

  • @github-actions run-benchmark - Run benchmark comparing base and merge commits for this PR
  • @github-actions publish-pr-on-npm - Build package from this PR and publish it on NPM

@yaacovCR

This comment has been minimized.

Copy link

github-actions bot commented Feb 1, 2024

@github-actions publish-pr-on-npm

@yaacovCR The latest changes of this PR are available on NPM as
graphql@17.0.0-alpha.3.canary.pr.4002.b3f6af2e83280d7830b2a01265e0977b7b68e2f4
Note: no gurantees provided so please use your own discretion.

Also you can depend on latest version built from this PR:
npm install --save graphql@canary-pr-4002

@yaacovCR
Copy link
Contributor Author

This is the starting point for #4026, a major rewrite of incremental delivery with the aim of following the spec edits at graphql/graphql-spec#1077

Considering that, if we are confident #4026 will get merged, this PR becomes important less for the implementation, and more for the test changes.

if we allow nesting of defers at the same level then we have to handle the case where a defer is completely empty -- not just empty because its fields are also contained within a parent.

this means that collectFields must directly return the new defer usages so that even empty defer usages can be used to create fragments so that we can track their children
@yaacovCR yaacovCR merged commit 51f41eb into graphql:main Mar 20, 2024
20 checks passed
@yaacovCR yaacovCR deleted the allow-nested branch March 20, 2024 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR: feature 🚀 requires increase of "minor" version number
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants