Fastro v0.83.0: renderToReadableStream

Admin • October 26, 2023


In this version, Fastro replace renderToString with renderToReadableStream.

renderToReadableStream is a more modern and powerful way to render React elements to a stream. It is especially useful for streaming large or complex elements to the client, or for elements that need to be rendered progressively.

Feature renderToString renderToReadableStream
Streaming No Yes
Suspense No Yes
Error handling Less robust More robust

renderToReadableStream renders the React element to a stream, which means that the HTML can be sent to the client as soon as it is available, without having to wait for the entire element to be rendered. This can improve the performance of the page load, especially for large or complex elements.

Fastro Framework is free and open source full stack web framework for Deno, TypeScript, Preact JS, and Tailwind CSS. Made with ♡ in Tulungagung