Solved hydration error

This commit is contained in:
Emir Karabeg
2025-01-29 19:22:59 -08:00
parent c5545397a9
commit 3d97f1df58

View File

@@ -17,7 +17,16 @@ export default function RootLayout({
<head> <head>
<script <script
dangerouslySetInnerHTML={{ dangerouslySetInnerHTML={{
__html: `window.INITIAL_TIMESTAMP = ${Date.now()};`, __html: `window.INITIAL_TIMESTAMP = 0;`,
}}
/>
<script
dangerouslySetInnerHTML={{
__html: `
if (typeof window !== 'undefined') {
window.INITIAL_TIMESTAMP = ${Date.now()};
}
`,
}} }}
/> />
</head> </head>