implement speed insights (w/ vercel)

This commit is contained in:
Aidan 2025-01-05 14:55:18 -05:00
parent e05a663fbb
commit 5cfb5c335b
2 changed files with 10 additions and 2 deletions

View File

@ -3,6 +3,7 @@ import type { Metadata } from 'next'
import { Inter } from 'next/font/google'
import '@fortawesome/fontawesome-svg-core/styles.css'
import { config } from '@fortawesome/fontawesome-svg-core'
import { SpeedInsights } from "@vercel/speed-insights/next"
config.autoAddCss = false
@ -20,7 +21,10 @@ export default function RootLayout({
}) {
return (
<html lang="en" className="dark">
<body className={`${inter.className} bg-gray-900 text-gray-100`}>{children}</body>
<body className={`${inter.className} bg-gray-900 text-gray-100`}>
{children}
<SpeedInsights />
</body>
</html>
)
}

View File

@ -13,6 +13,7 @@
"@fortawesome/free-brands-svg-icons": "^6.7.2",
"@fortawesome/free-solid-svg-icons": "^6.7.2",
"@fortawesome/react-fontawesome": "^0.2.2",
"@vercel/speed-insights": "^1.1.0",
"next": "15.1.3",
"react": "^19.0.0",
"react-dom": "^19.0.0"
@ -27,5 +28,8 @@
"eslint": "^9",
"eslint-config-next": "15.1.3",
"@eslint/eslintrc": "^3"
}
},
"trustedDependencies": [
"@vercel/speed-insights"
]
}