Skip to content

Commit

Permalink
Add @vercel/speed-insights
Browse files Browse the repository at this point in the history
  • Loading branch information
DarthGigi committed Jan 29, 2024
1 parent 3cac549 commit c52c2be
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 0 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
"dependencies": {
"@prisma/client": "5.8.1",
"@prisma/extension-accelerate": "^0.6.2",
"@vercel/speed-insights": "^1.0.8",
"bits-ui": "^0.15.1",
"clsx": "^2.1.0",
"cmdk-sv": "^0.0.13",
Expand Down
31 changes: 31 additions & 0 deletions pnpm-lock.yaml

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

4 changes: 4 additions & 0 deletions src/routes/+layout.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,12 @@
import Navbar from "$lib/layouts/Navbar.svelte";
import { preferences } from "$lib/stores/preferences";
import { inject } from "@vercel/analytics";
import { injectSpeedInsights } from "@vercel/speed-insights/sveltekit";
import "../app.css";
inject({ mode: dev ? "development" : "production", debug: false });
if (!dev) {
injectSpeedInsights();
}
preferences.subscribe((value) => {
if (typeof window !== "undefined") {
Expand Down

0 comments on commit c52c2be

Please sign in to comment.