-
Notifications
You must be signed in to change notification settings - Fork 23
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
gatsby-source-graphql & Apollo client #99
Comments
To clarify, you have one GraphQL backend, and you use it as both static and runtime queries at the same time. And you understand:
In this case, as you say, the plugin shouldn't parse any queries provided by Apollo, so it's an obvious bug. Can you provide settings and snippets? |
Right, even though at first I thought gatsby-plugin-typegen might be hackable to do both. So my typical code looks like this:
with my gatsby-config.js plugins set up
|
I saw you just filed another issue dotansimha/graphql-code-generator#4586 if this problem is caused in graphql-codegen config without this plugin. then I can track this as an upstream issue and contribute to there. will let you know after looking at the details and finding any workaround. |
This is fixed in v3 (current RC) v3 relies on Gatsby's |
rc.0 - implemente XState based scheduler - stabilize schema output - bump GCG - upgrade yarn to v3 - rewritten core logics - upgrade eslint to v8 - upgrade plugin's dependencies - pin graphql version - rewrite emitSchema service - rewriten emitPluginDocument service - rewriten codegen service - add TS & Flow examples rc.1 - skip running on cloud build - fix config validation - more contexture reporting - turn `flattenGeneratedTypesIncludeFragments` true - stabilize documents - change maybe type to use `null` instead of `undefined` - update README rc.2 - add mdx example - MDX example to validate regression of [#117] - update dependencies - added support for `GatsbyImageData` scalar Resolves #40 Resolves #103 Resolves #104 Resolves #109 Fixes #113 Fixes #117 Fixes #120 Resolves #122 Fixes #124 Resolves #131 Fixes #139, #99 Resolves #146 Fixes #157 Fixes #159 Fixes #160 Fixes #161 Fixes #162 Resolves #168 Resolves #169 Fixes #171 [#117]: #117
I am using gatsby-source-graphql to make remote data available under a given
fieldName
/namespace. I am accessing the same backend source with the Apollo client directly but without the fieldName that is defined for gatsby-source-graphql.From my understanding this is breaking the plugin for me right now. I get
Cannot query field ... on type "Query"
for all Apollo calls. Is there either a way toThank you for your help!
The text was updated successfully, but these errors were encountered: