-
-
Notifications
You must be signed in to change notification settings - Fork 10.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Chrome 131 & React 18.3.1, Hydration failed because the initial UI does not match what was rendered on the server #12663
Comments
Chrome 131 & React 19 & react-router 7.1.1 is OK |
React 19 is more forgiving about hydration issues. Do you have a browser extension installed that might be adding something to your page? I got this a lot with the Grammarly one, for instance. |
@timdorr was going to say exactly the same thing, it's the Language Tool for me that causes these errors |
Been dealing with these errors on firefox, too. This seems to have been caused by using DarkReader. Upgrading to react 19 shows a helpful error message with a diff: ...
<RemixErrorBoundary location={{pathname:"/", ...}}>
<RouterProvider2 router={{basename:"/", ...}}>
<RouterProvider flushSync={function} router={{basename:"/", ...}}>
<Router basename="/" location={{pathname:"/", ...}} navigationType="POP" navigator={{...}}>
<DataRoutes routes={[...]} future={{}} state={{...}}>
<RenderErrorBoundary location={{pathname:"/", ...}} revalidation="idle" component={<Layout>} ...>
<RenderedRoute match={{params:{}, ...}} routeContext={{...}}>
<Layout>
<html
lang="en"
- data-darkreader-mode="dynamic"
- data-darkreader-scheme="dark"
>
<head>
<meta>
<meta>
<Meta>
<Links>
<style
dangerouslySetInnerHTML={{
+ __html: "\n/* /app/app.css */\n*, ::before, ::after {\n --tw-border-spacing-x: 0;\n --..."
- __html: ""
}}
- className="darkreader darkreader--fallback"
- media="screen"
>
...
... |
I'm using React Router as a...
framework
Reproduction
https://github.com/JerrySLau/issues-react-router-example.git
commit 7a33c03a119556944acf911fd1c7f938cc72df2c
System Info
Used Package Manager
npm
Expected Behavior
render test page correctly(in safari 18.2 is ok, error in chrome 131.0.6778.205)
Actual Behavior
chunk-C6G4AGV4.js?v=fd8a3fd9:6973 Error: Hydration failed because the initial UI does not match what was rendered on the server.
at throwOnHydrationMismatch (chunk-4JV6IK6A.js?v=fd8a3fd9:9471:17)
at tryToClaimNextHydratableInstance (chunk-4JV6IK6A.js?v=fd8a3fd9:9492:15)
at updateHostComponent (chunk-4JV6IK6A.js?v=fd8a3fd9:14792:13)
at beginWork (chunk-4JV6IK6A.js?v=fd8a3fd9:15933:22)
at beginWork$1 (chunk-4JV6IK6A.js?v=fd8a3fd9:19751:22)
at performUnitOfWork (chunk-4JV6IK6A.js?v=fd8a3fd9:19196:20)
at workLoopConcurrent (chunk-4JV6IK6A.js?v=fd8a3fd9:19187:13)
at renderRootConcurrent (chunk-4JV6IK6A.js?v=fd8a3fd9:19162:15)
at performConcurrentWorkOnRoot (chunk-4JV6IK6A.js?v=fd8a3fd9:18676:46)
at workLoop (chunk-4JV6IK6A.js?v=fd8a3fd9:195:42)
The text was updated successfully, but these errors were encountered: