Skip to content

[Suspense] Document what activates a boundary and define Suspense-enabled frameworks#8505

Open
aurorascharff wants to merge 4 commits into
reactjs:mainfrom
aurorascharff:suspense-what-activates
Open

[Suspense] Document what activates a boundary and define Suspense-enabled frameworks#8505
aurorascharff wants to merge 4 commits into
reactjs:mainfrom
aurorascharff:suspense-what-activates

Conversation

@aurorascharff

@aurorascharff aurorascharff commented Jun 27, 2026

Copy link
Copy Markdown
Collaborator

Why: The Suspense reference said only Suspense-enabled data sources activate a boundary. That's outdated — many things activate Suspense now — and the term "Suspense-enabled framework" was used across several pages without ever being defined. The note also claimed framework-less data fetching was unsupported and undocumented, which the recent use() docs have since made untrue.

What: Replaces that note with a linkable section covering what actually activates a boundary, adds a definition of "Suspense-enabled framework," and points framework-less fetching at use() with a cached Promise. Also drops Next.js from the "Suspense-enabled frameworks" line, since it relies on Server Components and use() rather than a custom integration.

The behavior and framing were verified by the React team.

@aurorascharff aurorascharff changed the title Um [Suspense] Add 'What activates a Suspense boundary' section [Suspense] Add 'What activates a Suspense boundary' section Jun 27, 2026
@aurorascharff aurorascharff marked this pull request as ready for review June 27, 2026 20:55
Copilot AI review requested due to automatic review settings June 27, 2026 20:55
@github-actions

Copy link
Copy Markdown

Size changes

Details

📦 Next.js Bundle Analysis for react-dev

This analysis was generated by the Next.js Bundle Analysis action. 🤖

This PR introduced no changes to the JavaScript bundle! 🙌

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the <Suspense> reference to replace an outdated note with a new, linkable section that enumerates the different kinds of work/resources that can activate a Suspense boundary, while keeping data-fetching caveats in a <Note>.

Changes:

  • Adds a new “What activates a Suspense boundary” subsection with a broader activation list (e.g., lazy, use, stylesheets, fonts, images, SSR streaming, experimental defer).
  • Moves data-fetching caveats into a <Note> and tweaks wording around framework support (“built-in Suspense support”).
  • Removes Next.js from the earlier “Suspense-enabled frameworks” mention in favor of describing Server Components / use() behavior.

Docs review checklist (by guide)

docs-writer-reference

  • src/content/reference/react/Suspense.md:217 Bullet uses <img onLoad>-style wording that reads like JSX but isn’t valid JSX and is a bit unclear/contradictory in context.

docs-voice

  • src/content/reference/react/Suspense.md:217 Consider rephrasing to use inline code for the prop name (onLoad) and clarify the “not enabled by default” vs “opts out” wording.

docs-components

  • No issues found in the changed region (callout spacing and section divider usage look consistent).

docs-sandpack

  • No issues found related to Sandpack formatting/content in the changed region.

Please create a plan to address the unchecked checklist item(s).


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/content/reference/react/Suspense.md Outdated
<Note>
---

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

@MaxwellCohen MaxwellCohen Jun 27, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very excited to see these being called out and updated!

My understanding is that a "suspense enabled framework" is a framework that wraps these features that activates a suspense boundaries . If that is true could we specifically call it out what suspense enabled means?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this? 021f94d

Comment thread src/content/reference/react/Suspense.md Outdated
The exact way you would load data in the `Albums` component above depends on your framework. If you use a Suspense-enabled framework, you'll find the details in its data fetching documentation.
The exact way you would load data in the `Albums` component above depends on your framework. If you use a framework with built-in Suspense support, you'll find the details in its data fetching documentation.

Suspense-enabled data fetching without the use of an opinionated framework is not yet supported. The requirements for implementing a Suspense-enabled data source are unstable and undocumented. An official API for integrating data sources with Suspense will be released in a future version of React.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This list is out of date because of yours and @rickhanlonii great work on the use() docs.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch!!! Updating!

@aurorascharff aurorascharff changed the title [Suspense] Add 'What activates a Suspense boundary' section [Suspense] Document what activates a boundary and define Suspense-enabled frameworks Jun 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants