Skip to content

Commit c45c9b0

Browse files
committed
Update to be docs compliant and clarify images
1 parent 567cdd4 commit c45c9b0

1 file changed

Lines changed: 5 additions & 6 deletions

File tree

src/content/reference/react/Suspense.md

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,14 @@ title: <Suspense>
4040

4141
### What activates a Suspense boundary {/*what-activates-a-suspense-boundary*/}
4242

43-
A Suspense boundary waits for its content to be ready before revealing it. Any of the following blocks a boundary's content from being revealed:
43+
A Suspense boundary waits for its content to be ready before revealing it. Any of the following keeps a boundary from revealing its content:
4444

4545
- Lazy-loading component code with [`lazy`](/reference/react/lazy).
46-
- Reading a Promise with [`use`](/reference/react/use), including data streamed from [Server Components](/reference/rsc/server-components) or provided by a [Suspense-enabled framework](#suspense-enabled-frameworks).
46+
- Reading a Promise with [`use`](/reference/react/use), including data streamed from [Server Components](/reference/rsc/server-components) or loaded through a [Suspense-enabled framework](#suspense-enabled-frameworks).
4747
- Loading a stylesheet rendered with [`<link rel="stylesheet">` and a `precedence` prop.](/reference/react-dom/components/link#special-rendering-behavior) React blocks the boundary until the stylesheet loads, up to a timeout.
48-
- Loading fonts. When a boundary is revealed by streamed SSR content, React waits for [`document.fonts.ready`](https://developer.mozilla.org/en-US/docs/Web/API/FontFaceSet/ready) before showing it, up to a timeout, so text doesn't flash with a fallback font. Fonts also block a [`<ViewTransition>`](/reference/react/ViewTransition) update.
48+
- Loading fonts. When streamed server-side rendering (SSR) content reveals a boundary, React waits for [`document.fonts.ready`](https://developer.mozilla.org/en-US/docs/Web/API/FontFaceSet/ready) before showing it, up to a timeout, so text doesn't flash with a fallback font. Fonts also block a [`<ViewTransition>`](/reference/react/ViewTransition) update.
4949
- Streaming a large boundary's HTML during server rendering. React reveals the content as the HTML arrives.
50-
- Loading an image, where the `src` blocks the boundary until the image loads. This behavior is not enabled by default. When enabled, an `onLoad` handler opts an image out, and images in a [`<ViewTransition>`](/reference/react/ViewTransition) update opt in automatically.
50+
- Loading an image, where the `src` blocks the boundary until the image loads. This doesn't happen by default, but a [`<ViewTransition>`](/reference/react/ViewTransition) update turns it on automatically for its images, and you can add an `onLoad` handler to opt a specific image out.
5151
- <ExperimentalBadge /> Performing CPU-bound render work inside a `<Suspense>` boundary marked with the `defer` prop.
5252

5353
<Note>
@@ -231,7 +231,6 @@ async function getAlbums() {
231231

232232
By contrast, code that fetches data outside of `use`, such as inside an Effect, does not activate the boundary:
233233

234-
235234
<Sandpack>
236235

237236
```js src/App.js hidden
@@ -398,7 +397,7 @@ async function getAlbums() {
398397

399398
</Sandpack>
400399

401-
During streaming server rendering, a boundary also activates as its HTML arrives. With any streaming SSR API, React sends the shell with the `fallback` first, then streams in each boundary's HTML and swaps out its `fallback` as that content arrives. This progressive reveal applies only to content streamed from the server, not to updates on the client:
400+
During streaming server rendering, a boundary also activates as its HTML arrives. With any streaming SSR API, React sends [the shell](/reference/react-dom/server/renderToPipeableStream#specifying-what-goes-into-the-shell) with the `fallback` first, then streams in each boundary's HTML and swaps out its `fallback` as that content arrives. This progressive reveal applies only to content the server streams, not to updates on the client:
402401

403402
<Sandpack>
404403

0 commit comments

Comments
 (0)