Query Lists of Multiple Types using a Union in GraphQL

InstructorEve Porcello

Share this video with your friends

Send Tweet

Unions are used when we want a GraphQL field or list to handle multiple types of data. With a Union Type, we can define a field that could resolve completely different types of data. In this lesson, we will write a query that obtains a list of different pet types