From a06e261b95859c6487e0262471387892b274400c Mon Sep 17 00:00:00 2001 From: yujiseok Date: Tue, 11 Feb 2025 00:27:01 +0900 Subject: [PATCH 1/2] remove unnecessary colon in prerender.md documentation --- src/content/reference/react-dom/static/prerender.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/content/reference/react-dom/static/prerender.md b/src/content/reference/react-dom/static/prerender.md index 6450e4a3434..61047a1bb21 100644 --- a/src/content/reference/react-dom/static/prerender.md +++ b/src/content/reference/react-dom/static/prerender.md @@ -83,7 +83,7 @@ The static `prerender` API is used for static server-side generation (SSG). Unli ### Rendering a React tree to a stream of static HTML {/*rendering-a-react-tree-to-a-stream-of-static-html*/} -Call `prerender` to render your React tree to static HTML into a [Readable Web Stream:](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStream): +Call `prerender` to render your React tree to static HTML into a [Readable Web Stream:](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStream) ```js [[1, 4, ""], [2, 5, "['/main.js']"]] import { prerender } from 'react-dom/static'; From 5b76102975384bf91e0c831988517f1562ef0e9a Mon Sep 17 00:00:00 2001 From: yujiseok Date: Tue, 11 Feb 2025 21:39:04 +0900 Subject: [PATCH 2/2] remove unnecessary punctuation in prerenderToNodeStream.md --- .../reference/react-dom/static/prerenderToNodeStream.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/content/reference/react-dom/static/prerenderToNodeStream.md b/src/content/reference/react-dom/static/prerenderToNodeStream.md index eb12f4b3886..02f9f5a8075 100644 --- a/src/content/reference/react-dom/static/prerenderToNodeStream.md +++ b/src/content/reference/react-dom/static/prerenderToNodeStream.md @@ -4,7 +4,7 @@ title: prerenderToNodeStream -`prerenderToNodeStream` renders a React tree to a static HTML string using a [Node.js Stream.](https://nodejs.org/api/stream.html). +`prerenderToNodeStream` renders a React tree to a static HTML string using a [Node.js Stream.](https://nodejs.org/api/stream.html) ```js const {prelude} = await prerenderToNodeStream(reactNode, options?) @@ -64,7 +64,7 @@ On the client, call [`hydrateRoot`](/reference/react-dom/client/hydrateRoot) to `prerenderToNodeStream` returns a Promise: - If rendering the is successful, the Promise will resolve to an object containing: - - `prelude`: a [Node.js Stream.](https://nodejs.org/api/stream.html) of HTML. You can use this stream to send a response in chunks, or you can read the entire stream into a string. + - `prelude`: a [Node.js Stream](https://nodejs.org/api/stream.html) of HTML. You can use this stream to send a response in chunks, or you can read the entire stream into a string. - If rendering fails, the Promise will be rejected. [Use this to output a fallback shell.](#recovering-from-errors-inside-the-shell) @@ -81,7 +81,7 @@ The static `prerenderToNodeStream` API is used for static server-side generation ### Rendering a React tree to a stream of static HTML {/*rendering-a-react-tree-to-a-stream-of-static-html*/} -Call `prerenderToNodeStream` to render your React tree to static HTML into a [Node.js Stream.](https://nodejs.org/api/stream.html): +Call `prerenderToNodeStream` to render your React tree to static HTML into a [Node.js Stream:](https://nodejs.org/api/stream.html) ```js [[1, 5, ""], [2, 6, "['/main.js']"]] import { prerenderToNodeStream } from 'react-dom/static';