gatsby: All pages except index do not pre-render
Hey,
I might be missing something, but all my pages (generated from gatsby-node
or static ones from pages/
(e.g. pages/contact.js
) do not render content when I check the source. This is what I can see in view-source
:
<div id="___gatsby">
<div data-reactroot="">
<div></div>
</div>
</div>
However, the pages/index.js
page contains all html divs/imgs/etc in the source.
Can someone let me know if they’ve encountered this issue?
Thanks
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 10
- Comments: 45 (37 by maintainers)
I’m also running into this problem. Elements are not rendered as static HTML. Don’t appear in build or curl output. Can we reopen as it seems there wasn’t a clear solution provided?
🎉 Works now!!!
the only change is
Any luck with this?
Checked the source file in the dev tools and that seems to have all the content in there - but not present in
view-source
@ryanditjia yes, just checked the public index files after running build and content is there. However, once it gets deployed on Netlify, only the homepage has static content when viewing source.
I also tried enabling/disabling the prerendering setting in Netlify - same result