question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

The future of GraphQL Yoga

See original GitHub issue

It’s been almost 4 weeks since release of graphql-js v14. There’s plenty of PRs with deps update but the last commit on this repo was 26 days ago.

I’ve tried to update the deps in my project but graphql-yoga is still in 0.13.x ecosystem which results in plenty of errors like this:

npm WARN apollo-cache-control@0.1.1 requires a peer of graphql@0.10.x - 0.13.x but none is installed. You must install peer dependencies yourself.
npm WARN apollo-cache-inmemory@1.2.10 requires a peer of graphql@0.11.7 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
npm WARN apollo-server-core@1.4.0 requires a peer of graphql@^0.9.0 || ^0.10.0 || ^0.11.0
|| ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
npm WARN apollo-tracing@0.1.4 requires a peer of graphql@0.10.x - 0.13.x but none is installed. You must install peer dependencies yourself.
npm WARN apollo-upload-server@5.0.0 requires a peer of graphql@^0.13.1 but none is installed. You must install peer dependencies yourself.
npm WARN graphql-config@2.0.0 requires a peer of graphql@^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
npm WARN graphql-import@0.4.5 requires a peer of graphql@^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
npm WARN graphql-extensions@0.0.10 requires a peer of graphql@0.10.x - 0.13.x but none is
installed. You must install peer dependencies yourself.
npm WARN graphql-import@0.6.0 requires a peer of graphql@^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
npm WARN graphql-middleware@1.6.6 requires a peer of graphql@^0.13.2 but none is installed. You must install peer dependencies yourself.
npm WARN graphql-query-complexity@0.2.0 requires a peer of graphql@^0.13.2 but none is installed. You must install peer dependencies yourself.
npm WARN graphql-subscriptions@0.5.8 requires a peer of graphql@^0.10.5 || ^0.11.3 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
npm WARN graphql-tag@2.9.2 requires a peer of graphql@^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
npm WARN graphql-tools@3.1.1 requires a peer of graphql@^0.13.0 but none is installed. You must install peer dependencies yourself.

I also get famous Cannot use GraphQLSchema "[object GraphQLSchema]" from another module or realm. error while trying to use the subscriptions. And it also rejects to compile new GraphQLServer({ schema }) in TypeScript as there’s a conflict of GraphQLSchema typings between 0.13 and 14.0 😕

I would like to create a PR to fix that and upgrade the deps but someone has to merge it then 😄

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:22
  • Comments:30 (4 by maintainers)

github_iconTop GitHub Comments

52reactions
schicklingcommented, Oct 17, 2018

Hey everyone, there have been a lot of questions and confusion around the future of graphql-yoga lately. We want to use this GitHub issue as a forum to openly discuss in which direction the project should be headed.

Context & History

For context, we have released graphql-yoga almost one year ago when setting up a GraphQL server (using apollo-server or express-graphql) involved a good amount of boilerplate and manual work; it certainly wasn’t as easy as it should have been. This was true for rather simple GraphQL servers and became even more complex when features like subscriptions or middleware would have to be added.

Back then, we were striving to create the simplest solution for developers to get up-and-running with GraphQL. With graphql-yoga, we came up with a simple, straightforward and intuitive API to launch a GraphQL server that has been received very positively from the community.

GraphQL Yoga Today

Since the release of Apollo Server 2.0 which uses the same API as graphql-yoga and also comes with default support for GraphQL Playground (instead of graphiql), a lot of the value originally provided by graphql-yoga has vanished.

We have been scratching our heads over the past few weeks thinking hard about the future of graphql-yoga, whether we can find a direction that makes it so distinct from apollo-server to invest further in the project or switch to minimal-maintenance mode.

As is obvious from the state of this repository, graphql-yoga has not been maintained properly over the past few weeks. We apologize for that!

The Future of GraphQL Yoga

There currently are a few urgent issues with graphql-yoga that make it unusable in certain contexts, e.g. the 0.14 release of graphql-js. We’re already working on them and will release a new version in the coming days.

As for the mid-/longterm future of the project, we’d love to hear your opinions and discuss them openly! Do you have ideas or wishes how graphql-yoga could have a distinct value proposition over apollo-server? Are there any features that you’re missing in the current version? Whatever comes to mind that helps us make a decision regarding the future is more than welcome in this thread!

Thanks 💚

30reactions
LawJollacommented, Oct 18, 2018

I think Yoga, as is, still provides great value. For instance, it includes Apollo-Uploader out of the box for file uploads. The Express middleware API is miles better than Apollo 2.0.

Going forward, I think there’s room to be an opinionated Apollo Server. For instance, does anyone really care that you can use Apollo Server on top of Hapi? Choosing Express simplifies and streamlines everything. And I’d like to see more opinions incorporated like best practices for authentication and authorization.

In other words, keep doing what made Yoga so great – an opinionated, simpler API.

As a business decision, Yoga may not make sense any longer, but from a developer standpoint, I think it has legs… or downward dogs. (Oh yoga puns)

Read more comments on GitHub >

github_iconTop Results From Across the Web

The future of GraphQL Yoga · Issue #449 - GitHub
There currently are a few urgent issues with graphql-yoga that make it unusable in certain contexts, e.g. the 0.14 release of graphql-js ....
Read more >
Announcing GraphQL Yoga 2.0! – The Guild
GraphQL Yoga continues to boast a "convention over configuration" approach and the freedom to use your favorite libraries, from HTTP to schema- ...
Read more >
GraphQL Yoga 3 and ExpressJS - YouTube
Create a GraphQL server with the new GraphQL Yoga 3 and ExpressJS.Learn more and get the code:
Read more >
The Guild on Twitter: "GraphQL Yoga ❤️ Pothos GraphQL ...
With GraphQL Yoga 2.0, use your preferred schema builder with no configuration overhead! ... started with great talk about the future of GraphQL...
Read more >
Announcing GraphQL Armor support for GraphQL Yoga 2
When the GraphQL Ecosystem encounters Security · What do you get by using GraphQL Armor? · What does it look like to use...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found