datocms / gatsby-source-datocms

Official GatsbyJS source plugin to pull content from DatoCMS
MIT License
140 stars 50 forks source link

datoCmsSite queries return null #167

Closed ivanovyordan closed 2 years ago

ivanovyordan commented 2 years ago

I'm building a test blog and exploring the queries in the documentation. Everything works well so far except one thing.

Running this query in the CDA explorer works as expected:

query {
  _site {
    globalSeo {
      siteName
      titleSuffix
      twitterAccount
      facebookPageUrl
      fallbackSeo {
        title
        description
        image {
          url
        }
        twitterCard
      }
    }
  }
}
CDA

Running the query from the docs returns null.

query {
  datoCmsSite {
    globalSeo {
      siteName
      titleSuffix
      twitterAccount
      facebookPageUrl
      fallbackSeo {
        title
        description
        image {
          url
        }
        twitterCard
      }
    }
  }
}
Gatsby

What could be the reason for that behaviour in your opinion?

stefanoverna commented 2 years ago

Hi @ivanovyordan, I need some more info from you to assist:

Thanks

ivanovyordan commented 2 years ago

Hey @stefanoverna, I was testing the beta version of Gatsby 4. When I downgraded back to version 3 it all worked well.

Thanks.