Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
used for demonstration purposes
export const query = graphql`
query($slug: String!) {
site {
siteMetadata {
domain
}
}
allSiteSettingEntitySite {
edges {
node {
field_name
field_slogan
field_twitter_handle
}
}
}
nodeArticle(fields: { slug: { eq: $slug } }) {
title
path {
alias
}
field_overlay_color
fields {
slug
created_formatted
markdownBody {
childMarkdownRemark {
html
rawMarkdownBody
excerpt
}
}
}
relationships {
field_tags {
name
path {
alias
}
}
field_image {
relationships {
field_media_image {
localFile {
childImageSharp {
fluid(maxWidth: 1440, maxHeight: 560, cropFocus: CENTER) {
...GatsbyImageSharpFluid
}
}
}
}
}
}
field_related_post {
id
title
field_resume
path {
alias
}
fields {
created_formatted
markdownBody {
childMarkdownRemark {
excerpt
}
}
}
relationships {
field_image {
relationships {
field_media_image {
localFile {
childImageSharp {
fluid(maxWidth: 600, maxHeight: 400, cropFocus: CENTER) {
...GatsbyImageSharpFluid
}
}
}
}
}
}
}
}
}
}
}
`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment