Skip to content

Commit b0dfdf8

Browse files
committed
Bring back analytics
1 parent 8624f1d commit b0dfdf8

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/app/layout.tsx

+10
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,10 @@ import { Toaster } from '@/components/ui/toaster'
1111
import { env } from '@/lib/env'
1212
import { HeartFilledIcon } from '@radix-ui/react-icons'
1313
import type { Metadata, Viewport } from 'next'
14+
import { AxiomWebVitals } from 'next-axiom'
1415
import { NextIntlClientProvider, useTranslations } from 'next-intl'
1516
import { getLocale, getMessages } from 'next-intl/server'
17+
import PlausibleProvider from 'next-plausible'
1618
import Image from 'next/image'
1719
import Link from 'next/link'
1820
import { Suspense } from 'react'
@@ -233,6 +235,14 @@ export default async function RootLayout({
233235
const messages = await getMessages()
234236
return (
235237
<html lang={locale} suppressHydrationWarning>
238+
{env.PLAUSIBLE_DOMAIN && (
239+
<PlausibleProvider
240+
domain={env.PLAUSIBLE_DOMAIN}
241+
trackOutboundLinks
242+
manualPageviews
243+
/>
244+
)}
245+
<AxiomWebVitals />
236246
<ApplePwaSplash icon="/logo-with-text.png" color="#027756" />
237247
<body className="pt-16 min-h-[100dvh] flex flex-col items-stretch bg-slate-50 bg-opacity-30 dark:bg-background">
238248
<NextIntlClientProvider messages={messages}>

0 commit comments

Comments
 (0)