From 6320405fde682e04af6ad81e254b7dcb4240705f Mon Sep 17 00:00:00 2001 From: Vercel Date: Thu, 1 Jan 2026 15:18:45 +0000 Subject: [PATCH] Install Vercel Speed Insights for Astro MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Vercel Speed Insights Integration Report ### Summary Verified that Vercel Speed Insights has been successfully installed and configured for the Astro project. All required dependencies and components are properly in place. ### Status: ✅ COMPLETE The project already has Vercel Speed Insights fully integrated: #### Package Installation - ✅ Package `@vercel/speed-insights` is installed at version ^1.3.1 - ✅ Package `@vercel/analytics` is also installed at version 1.4.0 - ✅ Both packages are properly listed in package.json dependencies #### Layout Configuration - ✅ Location: `/src/layouts/Layout.astro` - ✅ Import: `import SpeedInsights from '@vercel/speed-insights/astro';` - ✅ Component placement: `` is positioned in the body element - ✅ Also includes Analytics component for comprehensive Vercel monitoring #### Verification - ✅ Build completed successfully with `npm run build` - ✅ No compilation errors or warnings related to Speed Insights - ✅ All dependencies installed correctly - ✅ Package-lock.json updated during npm install #### Features Enabled - Vercel Speed Insights for performance monitoring - Vercel Analytics for usage analytics - Both components support static and SSR Astro apps - Real-time performance data collection and monitoring ### Files Status - Modified: `package-lock.json` (updated by npm install to lock dependency versions) - No source code files required changes as integration was already complete ### Build Output - Build Status: ✓ Completed successfully - Output: Server build targeting Node.js adapter (@astrojs/node) - No errors or issues detected ### Notes - The integration follows best practices with components positioned appropriately: - Analytics component in head for early tracking - SpeedInsights component in body for performance monitoring - The implementation supports both static and SSR Astro applications - Speed Insights will automatically collect performance metrics and send them to Vercel Co-authored-by: Vercel --- package-lock.json | 45 ++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 42 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index 7810864..8971eea 100644 --- a/package-lock.json +++ b/package-lock.json @@ -14,6 +14,7 @@ "@aws-sdk/client-s3": "^3.940.0", "@sentry/astro": "^10.28.0", "@spotlightjs/astro": "^3.2.6", + "@vercel/analytics": "1.4.0", "@vercel/speed-insights": "^1.3.1", "astro": "^5.16.3", "postgres": "^3.4.7", @@ -164,6 +165,44 @@ "astro": "^5.0.0" } }, + "node_modules/@astrojs/vercel/node_modules/@vercel/analytics": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/@vercel/analytics/-/analytics-1.6.1.tgz", + "integrity": "sha512-oH9He/bEM+6oKlv3chWuOOcp8Y6fo6/PSro8hEkgCW3pu9/OiCXiUpRUogDh3Fs3LH2sosDrx8CxeOLBEE+afg==", + "license": "MPL-2.0", + "peerDependencies": { + "@remix-run/react": "^2", + "@sveltejs/kit": "^1 || ^2", + "next": ">= 13", + "react": "^18 || ^19 || ^19.0.0-rc", + "svelte": ">= 4", + "vue": "^3", + "vue-router": "^4" + }, + "peerDependenciesMeta": { + "@remix-run/react": { + "optional": true + }, + "@sveltejs/kit": { + "optional": true + }, + "next": { + "optional": true + }, + "react": { + "optional": true + }, + "svelte": { + "optional": true + }, + "vue": { + "optional": true + }, + "vue-router": { + "optional": true + } + } + }, "node_modules/@aws-crypto/crc32": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/@aws-crypto/crc32/-/crc32-5.2.0.tgz", @@ -6519,9 +6558,9 @@ "license": "ISC" }, "node_modules/@vercel/analytics": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/@vercel/analytics/-/analytics-1.6.1.tgz", - "integrity": "sha512-oH9He/bEM+6oKlv3chWuOOcp8Y6fo6/PSro8hEkgCW3pu9/OiCXiUpRUogDh3Fs3LH2sosDrx8CxeOLBEE+afg==", + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/@vercel/analytics/-/analytics-1.4.0.tgz", + "integrity": "sha512-eUwWW7l8nPJb0nJmjZuYp9o7YZ9XPj67lU9mEogaPXiFxq/SFB5DMnvQVk4aKcL8kFgotiYdDZWxdiNcWo7cgg==", "license": "MPL-2.0", "peerDependencies": { "@remix-run/react": "^2",