-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Use GraphQL Yoga #4712
Use GraphQL Yoga #4712
Conversation
2dcb8ef
to
27c8499
Compare
@ardatan thank you for this and the crazy quick turn around. The Guild never fails to impress me |
Updated from main to include new CI Auth Smoke Tests via #4673 |
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.
Had one question about the use of localhost
in the hanlderFn
.
9e2b4a3
to
6a49a7e
Compare
✅ Deploy Preview for redwoodjs-docs ready! 🔨 Explore the source changes: bf32ca2 🔍 Inspect the deploy log: https://app.netlify.com/sites/redwoodjs-docs/deploys/6238b1d61550bc000822740b 😎 Browse the preview: https://deploy-preview-4712--redwoodjs-docs.netlify.app |
I just realized I may have added back node-fetch as part of conflict resolution |
Meant to approve the changes not the PR
…postprocessing-nested-api-functions * 'main' of github.com:redwoodjs/redwood: Stying updates on docs site fix(deps): update typescript-eslint monorepo to v5.16.0 (redwoodjs#4862) fix(deps): update dependency cross-undici-fetch to v0.1.27 (redwoodjs#4858) fix(deps): update dependency @graphql-yoga/common to v0.1.0-canary-bfd2627.0 (redwoodjs#4857) chore(deps): update dependency zx to v6.0.7 (redwoodjs#4861) (docs) add Flightcontrol.dev Deploy (redwoodjs#4826) Handle case when requestContext is undefined getting protocol (redwoodjs#4864) Check for gql documents before running codegen (redwoodjs#4728) change flightcontrol setup to use yarn v3 and change cookie config (redwoodjs#4843) Forward -> Foreward Forward -> Foreward Typo Reorgnize tutorial into chapters (redwoodjs#4855) Fix linting warnings on new gql function (redwoodjs#4859) Use GraphQL Yoga (redwoodjs#4712) Fix url for tutorial path (redwoodjs#4852) chore(deps): update actions/cache action to v3 (redwoodjs#4847) Update link to tutorial deployment try learn's algolia config (redwoodjs#4851)
Just to confirm, this entirely replaces Helix, right? Helix is still mentioned in places like README and a few others but that might just be something that yet needs updating. BTW were there any issues with Helix or is Yoga just easier / more convenient to use? We'll be doing a similar decision soon 😊. |
Hi @borekb
Correct, the RedwoodJS GraphQL Server uses Yoga 2.0 now instead of Helix. Helix is still mentioned in places like README and a few others but that might just be something that yet needs updating. Thanks! We do need to clean up those mentions. Appreciate you finding them.
No, no issues with Helix. RedwoodJS decided to use Yoga based on the collaboration with the Guild. While @dotansimha can explain more, in short, (my take) Yoga takes the "best parts" of Helix, adds in what the Guild had learned from their customers using it in production, better integrates their envelop plugin system, and is now a project that they can maintain, support and improve faster and more easily than Helix (which is maintained by another party).
Sounds great. The transition for Redwood was really smooth. |
Hi!
As we discussed recently. We decided to create this PR to migrate your GraphQL Server implementation to GraphQL Yoga.
GraphQL Yoga is platform agnostic GraphQL Server for JavaScript environment that follows Web standards and supports GraphQL-over-HTTP spec together with GraphQL Multipart spec, defer/stream and SSE subscriptions.
https://graphql-yoga.com/
Thanks to Yoga, you don't need any extra configuration and code for Envelop integration, handling and parsing requests, CORS and healthchecks.
Also we saw that you're using node-fetch already for polyfilling Node and abstracting some HTTP stuff. This PR replaces it with cross-undici-fetch which is a smart ponyfill library like node-fetch but chooses the best fetch implementation according to your Node version etc(node-fetch for v14,undici for v16, native fetch for v17 etc).
As far as I see, there is no change in the user facing API (not sure if onHealthCheck is something for users) so in the docs.
We believe you can leverage more from Fetch API like we do in GraphQL Yoga so GraphQL Yoga can have tighter integration. We'd appreciate your feedback. Thanks!