Using graphql-codegen to generate resolvers with __resolveType & __resolveReference #8997
Answered
by
SiNONiMiTY
SiNONiMiTY
asked this question in
Q&A
-
|
Title says, if anyone can help point me on how to generate types for these types of resolvers. |
Beta Was this translation helpful? Give feedback.
Answered by
SiNONiMiTY
Feb 16, 2023
Replies: 2 comments
-
This is my configuration |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Found the answer for generating __resolveReference, there must be a However, I am still missing on how to generate the __resolveType definition. EDIT: It seems there must be Union or Interface types before codegen outputs the __resolveType definition. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
SiNONiMiTY
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Found the answer for generating __resolveReference, there must be a
@keydirective on the type that I want to be resolved.However, I am still missing on how to generate the __resolveType definition.
EDIT: It seems there must be Union or Interface types before codegen outputs the __resolveType definition.