Skip to content

Commit

Permalink
feat: umami analytics
Browse files Browse the repository at this point in the history
  • Loading branch information
leMedi committed May 15, 2024
1 parent feac7dc commit 188460b
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions apps/nextjs/src/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import { TRPCReactProvider } from "~/trpc/react";
import "~/app/globals.css";

import { env } from "~/env";
import Script from "next/script";

export const metadata: Metadata = {
metadataBase: new URL(
Expand Down Expand Up @@ -54,6 +55,14 @@ export default function RootLayout(props: { children: React.ReactNode }) {
<TRPCReactProvider>{props.children}</TRPCReactProvider>
<Toaster />
</ThemeProvider>

{env.NEXT_PUBLIC_URL === "https://recaply.io" && (
<Script
strategy="afterInteractive"
src="https://cloud.umami.is/script.js"
data-website-id="13b2ace0-8bc5-456d-87f3-2f5167f36419"
/>
)}
</body>
</html>
);
Expand Down

0 comments on commit 188460b

Please sign in to comment.