Description
The playground ssr-react uses in the entry-server.jsx the method ReactDOMServer.renderToString which does not support streaming or lazy / suspense components. I'd suggest to replace it with ReactDOMServer.renderToPipeableStream.
Suggested solution
I have made a working example based on the playground (a tiny bit more complex, but in essence the same) here:
https://github.com/technologiestiftung/vite-react-ssg-example/blob/feat/add-streaming-for-suspense/src/entry-server.tsx
If desired, I can make a PR to add these changes. As far as I can tell, nothing else would need to be changed.
Alternative
No response
Additional context
No response
Validations
Description
The playground ssr-react uses in the
entry-server.jsxthe methodReactDOMServer.renderToStringwhich does not support streaming or lazy / suspense components. I'd suggest to replace it withReactDOMServer.renderToPipeableStream.Suggested solution
I have made a working example based on the playground (a tiny bit more complex, but in essence the same) here:
https://github.com/technologiestiftung/vite-react-ssg-example/blob/feat/add-streaming-for-suspense/src/entry-server.tsx
If desired, I can make a PR to add these changes. As far as I can tell, nothing else would need to be changed.
Alternative
No response
Additional context
No response
Validations