Bump @astrojs/mdx from 5.0.6 to 6.0.3#8
Open
dependabot[bot] wants to merge 5 commits into
Open
Conversation
# Vercel Web Analytics Implementation
Successfully installed and configured Vercel Web Analytics for this Astro project.
## Changes Made
### 1. Package Installation
- Installed `@astrojs/vercel` (v10.0.8) - Vercel adapter for Astro
- Installed `@vercel/analytics` (v2.0.1) - Vercel Web Analytics package
- Updated `pnpm-lock.yaml` to reflect new dependencies
### 2. Astro Configuration (`astro.config.mjs`)
- Added import for `@astrojs/vercel` adapter
- Configured output mode to 'server' (required for Vercel adapter)
- Enabled Vercel adapter with `webAnalytics: { enabled: true }`
This configuration follows the official Astro-specific instructions from Vercel's documentation, which recommends configuring the adapter with the webAnalytics option enabled.
### 3. Content Security Policy Update (`vercel.json`)
Updated the CSP headers to allow Vercel Analytics scripts:
- Added `https://va.vercel-scripts.com` to `script-src`
- Added `https://va.vercel-scripts.com` and `https://*.vercel-insights.com` to `connect-src`
These additions ensure that Vercel Analytics can load and communicate properly without being blocked by the strict CSP policy.
### 4. Code Formatting
- Ran Prettier across the codebase to fix formatting issues
- All files now pass the format check
## Implementation Details
For Astro projects, Vercel Web Analytics works differently than other frameworks. Instead of manually adding a component to layouts, the analytics are automatically injected when the Vercel adapter is configured with `webAnalytics: { enabled: true }`. This is the recommended approach per the official Vercel documentation.
The adapter handles:
- Automatic injection of analytics scripts
- Server-side rendering compatibility
- Proper integration with Vercel's deployment infrastructure
## Testing
- Build completed successfully with 0 errors
- All TypeScript checks passed (only warnings for unused variables)
- Code formatting verified with Prettier
- Lock files updated correctly
## Next Steps
After deployment to Vercel:
1. Enable Web Analytics in the Vercel dashboard for this project
2. Visit the deployed site to generate initial traffic
3. Check the browser's Network tab for requests to `/_vercel/insights/*` to confirm tracking is active
4. View analytics data in the Vercel dashboard
## Files Modified
**Configuration Files:**
- `astro.config.mjs` - Added Vercel adapter with analytics enabled
- `vercel.json` - Updated CSP headers for analytics
- `package.json` - Added new dependencies
- `pnpm-lock.yaml` - Updated dependency lock file
**Source Files:**
- Multiple files formatted by Prettier (no functional changes)
- `README.md` - Formatted by Prettier
All changes preserve existing functionality while adding Vercel Web Analytics support.
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
…-tmbm1d Install Vercel Web Analytics
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
161a969 to
3338c58
Compare
# Conflicts: # src/content/docs/de/welcome-to-docs.mdx # src/content/docs/es/welcome-to-docs.mdx # src/content/docs/fr/welcome-to-docs.mdx # src/content/docs/ja/welcome-to-docs.mdx # src/content/docs/welcome-to-docs.mdx # src/content/docs/zh-cn/welcome-to-docs.mdx
Bumps [@astrojs/mdx](https://github.com/withastro/astro/tree/HEAD/packages/integrations/mdx) from 5.0.6 to 6.0.3. - [Release notes](https://github.com/withastro/astro/releases) - [Changelog](https://github.com/withastro/astro/blob/main/packages/integrations/mdx/CHANGELOG.md) - [Commits](https://github.com/withastro/astro/commits/@astrojs/mdx@6.0.3/packages/integrations/mdx) --- updated-dependencies: - dependency-name: "@astrojs/mdx" dependency-version: 6.0.3 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
3338c58 to
29be0ec
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bumps @astrojs/mdx from 5.0.6 to 6.0.3.
Release notes
Sourced from @astrojs/mdx's releases.
... (truncated)
Changelog
Sourced from @astrojs/mdx's changelog.
... (truncated)
Commits
0b879fb[ci] release (#16972)7e8d371chore: avoid an unwanted mdx major bump (#16977)4a31f90feat(satteri): Add support for Prism highlighting (#16969)fd7784e[ci] release (#16950)9a93d68feat: update to Sätteri 0.8.0 (#16955)3b75dc6[ci] release (#16884)c7157e6[ci] release (#16870)66593e3[ci] formatf732f3cfeat: add markdown processor abstraction (#16848)