Closed mcclntck closed 4 years ago
I fixed this by removing the StaticQuery and reverting to this.
const Layout = ({ children }) => (
<LayoutContainer className="div">
<Global styles={[globalStyles, typeStyles]} />
<div className="Layout">
<Header />
<main className="Layout__content">
{children}
</main>
<Footer />
</div>
</LayoutContainer>
)
export const query = graphql`
query SiteTitleQuery {
site {
siteMetadata {
title
}
}
}
`
Not sure what else there was to do, but it got it working.
This saved me, thanks!
Also I can confirm this error happened to me too on first project start. Using the code above fixes it.
Amazing @mcclntck. That did it. 🙌
Hey guys, I'm hitting an issue when trying to view my site. I got it working previously, but something changed and now the site just says
Loading (Static Query)
I'm not sure what I did, but can see this https://github.com/gatsbyjs/gatsby/issues/6350 has already been raised here.
What do I need to do to get this working again?
Thanks