Skip to content

Commit

Permalink
Add speed insights and use new @vercel/analytics for next (#173)
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiaslins authored Dec 1, 2024
1 parent 44039ad commit a20122d
Show file tree
Hide file tree
Showing 3 changed files with 70 additions and 10 deletions.
10 changes: 8 additions & 2 deletions app/analytics.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
"use client";
import { Analytics as AnalyticsComponent } from "@vercel/analytics/react";
import { Analytics as AnalyticsComponent } from "@vercel/analytics/next";
import { SpeedInsights } from "@vercel/speed-insights/next";

export function Analytics() {
return <AnalyticsComponent />;
return (
<>
<AnalyticsComponent />
<SpeedInsights />
</>
);
}
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"@next/mdx": "15.0.2",
"@types/node-fetch": "^2.6.2",
"@upstash/redis": "^1.20.1",
"@vercel/analytics": "^1.0.0",
"@vercel/analytics": "^1.4.1",
"@vercel/speed-insights": "^1.1.0",
"comma-number": "^2.1.0",
"date-fns": "^2.29.3",
"image-size": "^1.0.2",
Expand Down
67 changes: 60 additions & 7 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit a20122d

Please sign in to comment.