graphql / graphql/graphql.github.io

documentation should include `__resolveType` requirement for Union Type to return interface

Abierto
#474 0 comentarios 1 reacción 0 asignados Ver en GitHub
✏️ Editorial
Lenguaje dominante
TypeScript
Estrellas
889
Forks
1.5k
Merge medio
4 d 12 h
PR fusionados (30 d)
21

Descripción

There's no mention in the documentation that Union Types require a `__resolveType` field in the Resolver for the Union.

a good example of helpful information can be found at [Apollo's Documentation](https://www.apollographql.com/docs/graphql-tools/resolvers.html#Unions-and-interfaces)

> When you have a field in your schema that returns a union or interface type, you will need to specify an extra __resolveType field in your resolver map, which tells the GraphQL executor which type the result is, out of the available options.

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.