Skip to content

visum/next-renderToHTML-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Issue demo

Based on the ssr-caching demo. Adding a getServerSideProps hook to a page causes renderToHTML to send the response immediately and return null.

  • Run npm run dev to start the server.
  • Navigate to http://localhost:3000/
  • See in the console that the rendered data is null, the headers were sent, and a finish event handler on the req is triggered even though we commented out the lines that send the response.

From packages/next/next-server/server/text-server.ts renderToHTMLWithComponents()

if (html && isServerProps) {
  sendPayload(res, html, 'html', {
    private: isPreviewMode,
    stateful: true, // GSSP request
  })
  return null
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published