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

feat(gatsby-transformer-sharp): define ImageSharp as child of File type #16109

Merged
merged 1 commit into from
Jul 29, 2019

Conversation

stefanprobst
Copy link
Contributor

Querying on File.childImageSharp in a site/theme where no image files are present currently fails because children fields are not being created. This PR uses the new @childOf extension to explicitly define ImageSharp nodes as children of Filenodes.

Fixes #16099

Copy link
Contributor

@pieh pieh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@pieh pieh changed the title Explicitly define ImageSharp as child of File type feat(gatsby-transformer-sharp): define ImageSharp as child of File type Jul 29, 2019
@wardpeet wardpeet merged commit 272d22f into gatsbyjs:master Jul 29, 2019
@stefanprobst stefanprobst deleted the imagesharp-child branch July 29, 2019 06:37
LekoArts added a commit to LekoArts/gatsby-themes that referenced this pull request Aug 7, 2019
Previously I mentioned in the README that `projects` are mandatory for the emma theme as otherwise the query would break. Since gatsbyjs/gatsby#16109 fixed this bug, I removed the note and added a (hopefully) helpful placeholder text when someone's project doesn't have content in the `projects` folder.
anteroselin added a commit to anteroselin/gatsby-theme that referenced this pull request Mar 6, 2023
Previously I mentioned in the README that `projects` are mandatory for the emma theme as otherwise the query would break. Since gatsbyjs/gatsby#16109 fixed this bug, I removed the note and added a (hopefully) helpful placeholder text when someone's project doesn't have content in the `projects` folder.
infinitesky4444 added a commit to infinitesky4444/gatsby that referenced this pull request Jun 27, 2023
Previously I mentioned in the README that `projects` are mandatory for the emma theme as otherwise the query would break. Since gatsbyjs/gatsby#16109 fixed this bug, I removed the note and added a (hopefully) helpful placeholder text when someone's project doesn't have content in the `projects` folder.
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

Successfully merging this pull request may close these issues.

Schema Customization - Cannot Query Field "childImageSharpe" on type "File"
3 participants