Skip to content

Instantly share code, notes, and snippets.

@koras
Created May 6, 2026 00:22
Show Gist options
  • Select an option

  • Save koras/09e87fec3bcacbe6254f27100efaf92a to your computer and use it in GitHub Desktop.

Select an option

Save koras/09e87fec3bcacbe6254f27100efaf92a to your computer and use it in GitHub Desktop.
layout.tsx
import { Suspense } from 'react'
import YandexMetrika from '@/components/YandexMetrika'
export default function RootLayout({
children,
}: {
children: React.ReactNode
}) {
return (
<html lang="ru">
<body>
{children}
<Suspense fallback={null}>
<YandexMetrika />
</Suspense>
</body>
</html>
)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment