Replies: 1 comment
-
GraphQL spec does not allow arrays in unions |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I'm trying to create a Union type so I can either return an array of RateTypesPayload or ErrorPayload like this:
So I created a Union type as follows
This worked for non-array types, but for arrays, with the code above, the compiler throws the following error:
I also tried with
Array<typeof RateTypesPayload>
,[RateTypesPayload]
, etc.How can I make this work with an array?
Thank you!
Beta Was this translation helpful? Give feedback.
All reactions