From 93fbe4263718350eaa2ebbf68fd9ec2ac897aa84 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Greg=20Berg=C3=A9?= Date: Fri, 22 Dec 2023 11:34:06 +0400 Subject: [PATCH] docs(website): setup analytics --- website/package.json | 1 + website/pages/_app.tsx | 2 ++ website/pnpm-lock.yaml | 13 +++++++++++++ 3 files changed, 16 insertions(+) diff --git a/website/package.json b/website/package.json index 31c8a88..5642b0b 100644 --- a/website/package.json +++ b/website/package.json @@ -12,6 +12,7 @@ "author": "", "license": "ISC", "dependencies": { + "@vercel/analytics": "^1.1.1", "@vercel/og": "^0.6.1", "next": "^14.0.4", "nextra": "^2.13.2", diff --git a/website/pages/_app.tsx b/website/pages/_app.tsx index f58da83..8a32292 100644 --- a/website/pages/_app.tsx +++ b/website/pages/_app.tsx @@ -3,6 +3,7 @@ import "@/styles/globals.css"; import type { AppProps } from "next/app"; import localFont from "next/font/local"; import { Inter } from "next/font/google"; +import { Analytics } from "@vercel/analytics/react"; const inter = Inter({ subsets: ["latin"], variable: "--font-inter" }); const calSans = localFont({ @@ -16,6 +17,7 @@ export default function App({ Component, pageProps }: AppProps) { className={`${inter.variable} ${calSans.variable} antialiased font-sans`} > + ); } diff --git a/website/pnpm-lock.yaml b/website/pnpm-lock.yaml index 81b4628..bfab34c 100644 --- a/website/pnpm-lock.yaml +++ b/website/pnpm-lock.yaml @@ -5,6 +5,9 @@ settings: excludeLinksFromLockfile: false dependencies: + '@vercel/analytics': + specifier: ^1.1.1 + version: 1.1.1 '@vercel/og': specifier: ^0.6.1 version: 0.6.1 @@ -531,6 +534,12 @@ packages: resolution: {integrity: sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==} dev: false + /@vercel/analytics@1.1.1: + resolution: {integrity: sha512-+NqgNmSabg3IFfxYhrWCfB/H+RCUOCR5ExRudNG2+pcRehq628DJB5e1u1xqwpLtn4pAYii4D98w7kofORAGQA==} + dependencies: + server-only: 0.0.1 + dev: false + /@vercel/og@0.6.1: resolution: {integrity: sha512-o0ItpTQrn7TdBRiYLoBmATfunenfI87AZ5S/SvS9puxN4rjuNdDHSV6ND24WBt0FK2SljfM9LYowK/99ql2bEA==} engines: {node: '>=16'} @@ -3085,6 +3094,10 @@ packages: kind-of: 6.0.3 dev: false + /server-only@0.0.1: + resolution: {integrity: sha512-qepMx2JxAa5jjfzxG79yPPq+8BuFToHd1hm7kI+Z4zAq1ftQiP7HcxMhDDItrbtwVeLg/cY2JnKnrcFkmiswNA==} + dev: false + /shebang-command@1.2.0: resolution: {integrity: sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==} engines: {node: '>=0.10.0'}