Unverified Commit 8dd0b56f authored by Sam Ko's avatar Sam Ko Committed by GitHub

docs(errors): update suppressHydrationWarning section (#76521)

## Why?

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

- Related: https://github.com/reactjs/react.dev/pull/7651
- x-ref: https://github.com/vercel/next.js/discussions/75890
parent c505a4ca
...@@ -75,6 +75,11 @@ Sometimes content will inevitably differ between the server and client, such as ...@@ -75,6 +75,11 @@ Sometimes content will inevitably differ between the server and client, such as
<time datetime="2016-10-25" suppressHydrationWarning /> <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 ## 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. iOS attempts to detect phone numbers, email addresses, and other data in text content and convert them into links, leading to hydration mismatches.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment