Skip to content
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

failed extract queries from components #195

Closed
jafnz opened this issue Feb 10, 2020 · 3 comments
Closed

failed extract queries from components #195

jafnz opened this issue Feb 10, 2020 · 3 comments

Comments

@jafnz
Copy link

jafnz commented Feb 10, 2020

ERROR #85923  GRAPHQL

There was an error in your GraphQL query:

Cannot query field "contentfulAbout" on type "Query".

If you don't expect "contentfulAbout" to exist on the type "Query" it is most likely a typo.
However, if you expect "contentfulAbout" to exist there are a couple of solutions to common problems:

- If you added a new data source and/or changed something inside gatsby-node.js/gatsby-config.js, please try a restart of your development server
- The field might be accessible in another subfield, please try your query in GraphiQL and use the GraphiQL explorer to see which fields you can query and what shape they have
- You want to optionally use your field "contentfulAbout" and right now it is not used anywhere. Therefore Gatsby can't infer the type and add it to the GraphQL schema. A quick fix is to add a least one entry with that field ("dummy content")

It is recommended to explicitly type your GraphQL schema if you want to use optional fields. This way you don't have to add the mentioned "dummy content". Visit our docs to learn how you can define the schema for "Query":
https://www.gatsbyjs.org/docs/schema-customization/#creating-type-definitions

File: src/sections/About.js:50:11
@jafnz jafnz closed this as completed Feb 10, 2020
@jafnz jafnz reopened this Feb 10, 2020
@jafnz jafnz closed this as completed Feb 10, 2020
@jung-youjin
Copy link

Hi, I'm facing the same issue. Could you tell me how you solved this problem? Thanks!

@EmaSuriano
Copy link
Owner

Hi @jung-youjin are you still facing this issue with the new setup with themes?

@jung-youjin
Copy link

@EmaSuriano Nope! I got this fixed and everything's fine now :) Thanks for keeping up!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants