Skip to content

Commit b1d7bbe

Browse files
Update src/content/reference/react-dom/client/hydrateRoot.md
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 09e10a6 commit b1d7bbe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/content/reference/react-dom/client/hydrateRoot.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -564,7 +564,7 @@ This renders a different value on the server and the client, so hydration fails.
564564
565565
1. Open the browser console and find the first hydration warning.
566566
2. Look for changing values in render (`Math.random()`, `Date.now()`). Move them to server data or calculate them after hydration in an Effect.
567-
3. Keep browser only code out of render. Read `window`, `document`, and similar APIs in an Effect or event handler.
567+
3. Keep browser-only code out of render. Read `window`, `document`, and similar APIs in an Effect or event handler.
568568
4. Make sure the first client render uses the same data as the server render.
569569
5. If one mismatch is expected (for example, a timestamp), use `suppressHydrationWarning={true}` on that element.
570570

0 commit comments

Comments
 (0)