Skip to content

feat(docs): add databuddy#350

Merged
HugoRCD merged 2 commits into
mainfrom
feat/databuddy
May 24, 2026
Merged

feat(docs): add databuddy#350
HugoRCD merged 2 commits into
mainfrom
feat/databuddy

Conversation

@HugoRCD
Copy link
Copy Markdown
Owner

@HugoRCD HugoRCD commented May 24, 2026

🔗 Linked issue

📚 Description

📝 Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

Summary by CodeRabbit

  • New Features
    • Integrated an analytics module into the documentation site with comprehensive tracking: Web Vitals, runtime errors, navigation/hash changes, outgoing links, user interactions, and custom attributes.
  • Chores
    • Added the analytics dependency and updated workspace release tooling exclusions to accommodate the new module.

Review Change Stack

@HugoRCD HugoRCD self-assigned this May 24, 2026
@vercel
Copy link
Copy Markdown

vercel Bot commented May 24, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
evlog-docs Ready Ready Preview, Comment, Open in v0 May 24, 2026 12:43pm
just-use-evlog Ready Ready Preview, Comment May 24, 2026 12:43pm

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 24, 2026

Thank you for following the naming conventions! 🙏

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 24, 2026

Caution

Review failed

Pull request was closed or merged during review

📝 Walkthrough

Walkthrough

Adds the @databuddy/nuxt dependency and workspace exclusion, and registers/configures the module in apps/docs/nuxt.config.ts with a fixed clientId and tracking enabled for web vitals, errors, hash changes, outgoing links, interactions, and attributes.

Changes

DataBuddy Module Integration

Layer / File(s) Summary
Module dependency and workspace update
apps/docs/package.json, pnpm-workspace.yaml
Adds @databuddy/nuxt at version ^2.4.20 to apps/docs/package.json and adds it to minimumReleaseAgeExclude in pnpm-workspace.yaml.
Module configuration
apps/docs/nuxt.config.ts
Registers @databuddy/nuxt in Nuxt config and configures databuddy with a fixed clientId and enabled tracking flags: webVitals, errors, hashChanges, outgoingLinks, interactions, attributes.

🎯 3 (Moderate) | ⏱️ ~20 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The PR description is empty of substantive content—only the template structure is present with all sections unfilled, including no linked issue, no change description, and no completed checklist items. Fill in the description template with: a linked issue or discussion, a detailed explanation of why databuddy was added and what it does, and check the relevant checklist items. Include context on the tracking configuration being enabled.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title 'feat(docs): add databuddy' clearly and concisely summarizes the main change: adding databuddy integration to the docs application following conventional commits.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/databuddy

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@apps/docs/nuxt.config.ts`:
- Around line 14-16: The project currently registers three observability modules
in nuxt.config.ts ('`@vercel/analytics`', '`@vercel/speed-insights`',
'`@databuddy/nuxt`'), which likely overlap; decide which tool(s) to keep and
update the modules array accordingly: if DataBuddy replaces Vercel tools, remove
'`@vercel/analytics`' and '`@vercel/speed-insights`' entries; if each is required,
add an inline comment in nuxt.config.ts explaining the distinct purpose of each
('`@vercel/analytics`' for user analytics, '`@vercel/speed-insights`' for perf
metrics, '`@databuddy/nuxt`' for Vitals/errors) and verify no duplicate Web
Vitals/error instrumentation is registered in related setup code (search for any
init hooks for DataBuddy, Vercel Analytics, or Speed Insights) to avoid
double-reporting.
- Line 20: Replace the hardcoded clientId value in the nuxt config with an
environment-driven value: read process.env.NUXT_PUBLIC_DATABUDDY_CLIENT_ID (or a
similar NUXT_PUBLIC_ variable) and use that for the clientId in the
configuration (optionally falling back to the current literal
'389b5a41-31cb-4ea4-a5e8-8ec3ac4ffccc' if the env var is unset); update the
reference around the clientId key so the app picks up different IDs per
environment and document setting NUXT_PUBLIC_DATABUDDY_CLIENT_ID in env files.

In `@apps/docs/package.json`:
- Line 14: The CI is failing because package.json was updated to add the
dependency "`@databuddy/nuxt`" but the lockfile wasn't regenerated; run "pnpm
install" locally to update pnpm-lock.yaml, verify the lockfile changes, and
commit the updated pnpm-lock.yaml so the CI uses the correct, in-sync dependency
graph.
- Line 14: Replace the invalid dependency entry "`@databuddy/nuxt`": "^1.0.0" with
the correct package used on npm—e.g., add "`@databuddy/sdk`": "^2.3.29" (or the
latest v2.x) and, if you need the Nuxt integration for Databuddy analytics,
include the appropriate integration package such as "`@nuxt/scripts`" (or the
official Databuddy Nuxt integration if one exists) in dependencies; update
package.json dependency keys accordingly and run npm install to verify
resolution, making sure to remove the non-existent "`@databuddy/nuxt`" entry.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 140ecfd1-0989-4099-9264-aa5ae0219fbb

📥 Commits

Reviewing files that changed from the base of the PR and between 6d4d87c and 40dc887.

📒 Files selected for processing (2)
  • apps/docs/nuxt.config.ts
  • apps/docs/package.json

Comment thread apps/docs/nuxt.config.ts
Comment on lines 14 to +16
'@vercel/analytics',
'@vercel/speed-insights',
'@databuddy/nuxt',
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick | 🔵 Trivial

Multiple observability tools may have overlapping functionality.

The docs app now has three tracking solutions:

  • @vercel/analytics - user analytics
  • @vercel/speed-insights - performance metrics (Web Vitals)
  • @databuddy/nuxt - tracks Web Vitals, errors, interactions, etc.

Consider whether this overlap is intentional. Multiple tracking scripts can:

  • Impact page load performance
  • Increase bundle size
  • Create redundant data streams

If DataBuddy is replacing Vercel's tools, consider removing the older modules. If each serves a distinct purpose, document why multiple solutions are needed.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@apps/docs/nuxt.config.ts` around lines 14 - 16, The project currently
registers three observability modules in nuxt.config.ts ('`@vercel/analytics`',
'`@vercel/speed-insights`', '`@databuddy/nuxt`'), which likely overlap; decide which
tool(s) to keep and update the modules array accordingly: if DataBuddy replaces
Vercel tools, remove '`@vercel/analytics`' and '`@vercel/speed-insights`' entries;
if each is required, add an inline comment in nuxt.config.ts explaining the
distinct purpose of each ('`@vercel/analytics`' for user analytics,
'`@vercel/speed-insights`' for perf metrics, '`@databuddy/nuxt`' for Vitals/errors)
and verify no duplicate Web Vitals/error instrumentation is registered in
related setup code (search for any init hooks for DataBuddy, Vercel Analytics,
or Speed Insights) to avoid double-reporting.

Comment thread apps/docs/nuxt.config.ts
],

databuddy: {
clientId: '389b5a41-31cb-4ea4-a5e8-8ec3ac4ffccc',
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick | 🔵 Trivial | 💤 Low value

Consider using an environment variable for the clientId.

The clientId is currently hardcoded in the configuration. While tracking client IDs are typically public (not secrets), using an environment variable would provide better flexibility across different environments (dev, staging, production).

♻️ Optional refactor to use environment variable

In nuxt.config.ts:

  databuddy: {
-   clientId: '389b5a41-31cb-4ea4-a5e8-8ec3ac4ffccc',
+   clientId: process.env.NUXT_PUBLIC_DATABUDDY_CLIENT_ID || '',
    trackWebVitals: true,

Then set NUXT_PUBLIC_DATABUDDY_CLIENT_ID in your environment configuration.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
clientId: '389b5a41-31cb-4ea4-a5e8-8ec3ac4ffccc',
clientId: process.env.NUXT_PUBLIC_DATABUDDY_CLIENT_ID || '',
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@apps/docs/nuxt.config.ts` at line 20, Replace the hardcoded clientId value in
the nuxt config with an environment-driven value: read
process.env.NUXT_PUBLIC_DATABUDDY_CLIENT_ID (or a similar NUXT_PUBLIC_ variable)
and use that for the clientId in the configuration (optionally falling back to
the current literal '389b5a41-31cb-4ea4-a5e8-8ec3ac4ffccc' if the env var is
unset); update the reference around the clientId key so the app picks up
different IDs per environment and document setting
NUXT_PUBLIC_DATABUDDY_CLIENT_ID in env files.

Comment thread apps/docs/package.json Outdated
@HugoRCD HugoRCD merged commit aa3ae0d into main May 24, 2026
14 of 17 checks passed
@HugoRCD HugoRCD deleted the feat/databuddy branch May 24, 2026 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant