-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PossibleTypes not working as intended #11878
Comments
This part is likely your problem. Apollo client needs to have the |
Yes, thanks @dylanwulf! @Gowthaman-Opti-Twin can you confirm this solved your issue? |
Yep, that's the issue. It is working fine now. Thanks |
Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo Client usage and allow us to serve you better. |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
I have a query that uses union types inside it.
sample query
when I try to use
useQuery
from apolloClient it is returning the person object with empty brackets[{},{}]
but when usingfetch()
it is returning[{id:232, lightsaber:green},{id:242, beskar: old}]
I tried specifying the union type in the apollo client
it is not returning the any properties inside the object just an empty object
{}
here is the useQuery
const {data:QueryData} = useQuery<PersonQuery>(GET_PERSON)
The text was updated successfully, but these errors were encountered: