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.

How to use union types with graphql-yoga?

See original GitHub issue

Hi, is there any support for union types yet in graphql-yoga? It seems to need a resolveType function to determine the actual type of an object at runtime. I couldn’t find any place refering to supporting this so far.

Taking this opportunity to express my deep admiration for the work you guys at graphcool have been doing. Amazing developer experience across the board since the release of the graphcool framework, and really excited at what the stack is becoming with native gql db + yoga as api gateway 👍.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:4
  • Comments:13 (9 by maintainers)

github_iconTop GitHub Comments

3reactions
simonjoomcommented, Aug 13, 2018

hello Who want to learn Prisma or contribute in our Project?: We have got a ready react-native project who use prisma already setup with all techno apollo2 webpack4 react-scripts inside: It’s here https://github.com/simonjoom/react-native-project Read README, We are ready to hire competent and efficient developper who use prisma API CRUD in efficient way for our project

3reactions
schicklingcommented, Mar 11, 2018

@eliperelman would you be open to adding an example via PR demonstrating how to use interfaces + unions?

Read more comments on GitHub >

github_iconTop Results From Across the Web

GraphQL Interfaces (and Union Types) with Prisma and Yoga
The GraphQL schema specification supports Interfaces and Union Types. An Interface is an abstract type that includes a certain set of fields ...
Read more >
How to use union types with graphql-yoga? · Issue #121
Hi, is there any support for union types yet in graphql-yoga? It seems to need a resolveType function to determine the actual type...
Read more >
Error Handling with GraphQL Union Types - YouTube
Implement better error handling with GraphQL by using the Type System.Learn more about GraphQL : ...
Read more >
GraphQL Error Handling with Union Types - Episode #30
GraphQL Error Handling with Union Types. Implement better error handling with GraphQL by using the Type System.
Read more >
Getting the Best of TypeScript and GraphQL: Union Types
We can create Union and Interface types in both TypeScript and GraphQL, which helps us to better define the API of a server...
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