8000 Document's `renderPage` does not return html on error · Issue #3326 · vercel/next.js · GitHub
[go: up one dir, main page]

Skip to content

Document's renderPage does not return html on error #3326

New issue
8000

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

Closed
martinhorsky opened this issue Nov 23, 2017 · 2 comments
Closed

Document's renderPage does not return html on error #3326

martinhorsky opened this issue Nov 23, 2017 · 2 comments

Comments

@martinhorsky
Copy link

Before 4.1.3 release the renderPage from context of Document's getInitialProps always returned html no matter what. It also happened in the case of error.

After commit #3142 html can be undefined which causes issue when you depend on it. Before it was error page (with 500) overlayed with error code - that was ok.

Now, when you use for example glamorous or glamor with it's server side rendering it will not work. See code: https://github.com/zeit/next.js/blob/20af8cdabece57de21d9cbcdba7361a09bf66fbb/examples/with-glamor/pages/_document.js#L7

Currently when you make syntactic error it will propagate as glamor error and you need to always reload the page after this happens (hot reloading stops working).

@janedbal
Copy link

I find this issue very annoying since it breaks hot reloading...

@timneutkens
Copy link
Member

Feel free to add it to the docs.

@lock lock bot locked as resolved and limited conversation to collaborators Mar 16, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
0