Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the section about web analytics in the vercel adaptor. #10375

Open
Abdo-reda opened this issue Dec 15, 2024 · 1 comment
Open

Update the section about web analytics in the vercel adaptor. #10375

Abdo-reda opened this issue Dec 15, 2024 · 1 comment
Labels
good first issue Good for newcomers help wanted Issues looking for someone to run with them! improve documentation Enhance existing documentation (e.g. add an example, improve description)

Comments

@Abdo-reda
Copy link

Abdo-reda commented Dec 15, 2024

📚 Subject area/topic

Vercel Adaptor, Web Analytics.

📋 Page(s) affected (or suggested, for new content)

https://docs.astro.build/en/guides/integrations-guide/vercel/#webanalytics

📋 Description of content that is out-of-date or incorrect

Currenlty, the newer versions of @vercel/analytics, doesn't need web Analytics to be configured to true in the astro.config.js. It works by adding the component to the html.

Reference vercel documentation select astro in the framework in the top right dropdown.

image

🖥️ Reproduction in StackBlitz (if reporting incorrect content or code samples)

No response

@Abdo-reda Abdo-reda added the improve documentation Enhance existing documentation (e.g. add an example, improve description) label Dec 15, 2024
@sarah11918
Copy link
Member

Thank you for letting us know!

Since our entry is in docs is for the configuration property shown here:
image

... maybe the solution is to update the wording to show:

With `@vercel/[email protected]` or earlier, you can set `webAnalytics: { enabled: true }` in your Astro config to inject Vercel’s tracking scripts into all of your pages.

For `@vercel/[email protected]` and later, use Vercel's Analytics component to enable [Vercel Web Analytics]((https://vercel.com/docs/concepts/analytics) instead.

This keeps the Astro configuration option documented (which could still be in use in some older Vercel projects) but mentions that it is only relevant for earlier versions of Vercel's analytics. We should not document their component ourselves, as that is their content and subject to change, but we should instead link to it.

I'll add help wanted to this issue and would accept a PR if someone would like to update the Vercel adapter docs!

@sarah11918 sarah11918 added good first issue Good for newcomers help wanted Issues looking for someone to run with them! labels Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted Issues looking for someone to run with them! improve documentation Enhance existing documentation (e.g. add an example, improve description)
Projects
None yet
Development

No branches or pull requests

2 participants