Skip to content

Commit

Permalink
docs(errors): update suppressHydrationWarning section (#76521)
Browse files Browse the repository at this point in the history
## Why?

We should clarify that React will **not** attempt to patch mismatched text content when using `suppressHydrationWarning`.

- Related: reactjs/react.dev#7651
- x-ref: #75890
  • Loading branch information
samcx authored Feb 26, 2025
1 parent c505a4c commit 8dd0b56
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions errors/react-hydration-error.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,11 @@ Sometimes content will inevitably differ between the server and client, such as
<time datetime="2016-10-25" suppressHydrationWarning />
```

> **Good to know:**
>
> - This only works one level deep, and is intended to be an escape hatch. Don’t overuse it.
> - React will **not** attempt to patch mismatched text content when `suppressHydrationWarning={true}` is set.
## Common iOS issues

iOS attempts to detect phone numbers, email addresses, and other data in text content and convert them into links, leading to hydration mismatches.
Expand Down

0 comments on commit 8dd0b56

Please sign in to comment.