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

[v2] PageRenderer exported from gatsby doesn't work in production #5920

Closed
pieh opened this issue Jun 15, 2018 · 1 comment · Fixed by #5986
Closed

[v2] PageRenderer exported from gatsby doesn't work in production #5920

pieh opened this issue Jun 15, 2018 · 1 comment · Fixed by #5986
Assignees
Labels
type: bug An issue or pull request relating to a bug in Gatsby

Comments

@pieh
Copy link
Contributor

pieh commented Jun 15, 2018

https://github.com/gatsbyjs/gatsby/blob/v2/packages/gatsby/src/cache-dir/gatsby-browser-entry.js#L8-L15
JSONStore used there isn't used in production anywhere else and will never render anything in production. My hacky solution to use page-renderer.js directly instead of JSONStore there for production builds seems to work, but I need to investigate it more and figure out not hacky solution to make it work for both production and development.

For reference - here's hacky fix - pieh@fc3b255

@KyleAMathews
Copy link
Contributor

Seems like a reasonable hack :-) Main thing is to avoid loading any extra code into production.

@m-allanson m-allanson added the type: bug An issue or pull request relating to a bug in Gatsby label Jun 19, 2018
@pieh pieh self-assigned this Jun 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug An issue or pull request relating to a bug in Gatsby
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants