Skip to content

Commit

Permalink
feat: @vercel/analytics and @vercel/speed-insights (#98)
Browse files Browse the repository at this point in the history
  • Loading branch information
ojj1123 authored Mar 26, 2024
1 parent 8d7d344 commit b110868
Show file tree
Hide file tree
Showing 8 changed files with 142 additions and 1 deletion.
82 changes: 82 additions & 0 deletions .pnp.cjs

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

Binary file not shown.
Binary file not shown.
Binary file not shown.
2 changes: 1 addition & 1 deletion next.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* eslint-disable @typescript-eslint/no-var-requires */
const IS_DEV = process.env.NODE_ENV === "development";

const { withPlugins, extend } = require("next-compose-plugins");
const { extend } = require("next-compose-plugins");
const withPWA = require("next-pwa")({
dest: "public",
disable: IS_DEV,
Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@
"@sentry/nextjs": "^7.44.0",
"@tanstack/react-query": "^4.19.1",
"@use-gesture/react": "^10.2.24",
"@vercel/analytics": "^1.2.2",
"@vercel/speed-insights": "^1.0.10",
"@zag-js/react": "^0.22.0",
"@zag-js/tags-input": "^0.22.0",
"axios": "^1.2.0",
Expand Down
4 changes: 4 additions & 0 deletions src/pages/_app.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
import "@/styles/globals.css";

import { Analytics } from "@vercel/analytics/react";
import { SpeedInsights } from "@vercel/speed-insights/next";
import type { AppProps } from "next/app";
import Head from "next/head";
import { useRouter } from "next/router";
Expand Down Expand Up @@ -64,6 +66,8 @@ const App = ({ Component, pageProps }: AppProps<DefaultPageProps>) => {
<ToastContainer />
<SignUpModal />
<Component {...pageProps} />
<Analytics />
<SpeedInsights />
</QueryErrorBoundary>
</OverlayProvider>
</Layout>
Expand Down
53 changes: 53 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6082,6 +6082,50 @@ __metadata:
languageName: node
linkType: hard

"@vercel/analytics@npm:^1.2.2":
version: 1.2.2
resolution: "@vercel/analytics@npm:1.2.2"
dependencies:
server-only: ^0.0.1
peerDependencies:
next: ">= 13"
react: ^18 || ^19
peerDependenciesMeta:
next:
optional: true
react:
optional: true
checksum: 5913caeb2077d3d9c2eddabed90e40e29762e9e53941d3e1337daa0a60423ffef2a2c0b5a743ff37ea1aa9cfe7eb3159e4dff91cd4843a8503be5680c2faa98d
languageName: node
linkType: hard

"@vercel/speed-insights@npm:^1.0.10":
version: 1.0.10
resolution: "@vercel/speed-insights@npm:1.0.10"
peerDependencies:
"@sveltejs/kit": ^1 || ^2
next: ">= 13"
react: ^18 || ^19
svelte: ^4
vue: ^3
vue-router: ^4
peerDependenciesMeta:
"@sveltejs/kit":
optional: true
next:
optional: true
react:
optional: true
svelte:
optional: true
vue:
optional: true
vue-router:
optional: true
checksum: 26171c424ed725bbb82020818428a37e54715dfba58ae8ccff53c1bb58787f3713a9d8695afbbb5439555b92614f099fdb5188f80d9855818fddf7c192e8033e
languageName: node
linkType: hard

"@webassemblyjs/ast@npm:1.11.1":
version: 1.11.1
resolution: "@webassemblyjs/ast@npm:1.11.1"
Expand Down Expand Up @@ -17597,6 +17641,13 @@ __metadata:
languageName: node
linkType: hard

"server-only@npm:^0.0.1":
version: 0.0.1
resolution: "server-only@npm:0.0.1"
checksum: c432348956641ea3f460af8dc3765f3a1bdbcf7a1e0205b0756d868e6e6fe8934cdee6bff68401a1dd49ba4a831c75916517a877446d54b334f7de36fa273e53
languageName: node
linkType: hard

"set-blocking@npm:^2.0.0":
version: 2.0.0
resolution: "set-blocking@npm:2.0.0"
Expand Down Expand Up @@ -18830,6 +18881,8 @@ __metadata:
"@typescript-eslint/eslint-plugin": ^5.45.0
"@typescript-eslint/parser": ^5.45.0
"@use-gesture/react": ^10.2.24
"@vercel/analytics": ^1.2.2
"@vercel/speed-insights": ^1.0.10
"@zag-js/react": ^0.22.0
"@zag-js/tags-input": ^0.22.0
autoprefixer: ^10.4.13
Expand Down

0 comments on commit b110868

Please sign in to comment.