Skip to content

feat(nuxt): Register nuxt route provider - #23794

Open
logaretm wants to merge 6 commits into
awad/route-provider-vue-appfrom
awad/route-provider-nuxt
Open

logaretm wants to merge 6 commits into
awad/route-provider-vue-appfrom
awad/route-provider-nuxt

Conversation

@logaretm

Copy link
Copy Markdown
Member

Registers a route provider for Nuxt in the client plugin, outside the __SENTRY_TRACING__ guard.

Nuxt installs the router before its plugins run, so the plugin can read it straight off nuxtApp rather than waiting for a Vue app the way @sentry/vue has to. Reuses createVueRouteProvider from #23553's successor rather than reimplementing the vue-router resolve handling.

Because it sits outside the tracing guard, route parameterization survives when tracing is tree-shaken away.

Part of #23556

@github-actions

Copy link
Copy Markdown
Contributor

This pull request has gone three weeks without activity. In another week, I will close it.

But! If you comment or otherwise update it, I will reset the clock, and if you apply the label PR: no-auto-close I will leave it alone ... forever!

@github-actions

github-actions Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

size-limit report 📦

Path Size % Change Change
@sentry/browser 29.51 kB +0.51% +148 B 🔺
@sentry/browser - with treeshaking flags 27.68 kB +0.13% +34 B 🔺
@sentry/browser - with treeshaking flags tracing without tracing 27.58 kB +0.14% +38 B 🔺
@sentry/browser (incl. Tracing) 51.46 kB +0.31% +154 B 🔺
@sentry/browser (incl. Tracing + Span Streaming) 51.47 kB +0.3% +149 B 🔺
@sentry/browser (incl. Tracing, Profiling) 54.47 kB +0.31% +164 B 🔺
@sentry/browser (incl. Tracing, Replay) 91.05 kB +0.18% +155 B 🔺
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 80.03 kB +0.05% +36 B 🔺
@sentry/browser (incl. Tracing, Replay with Canvas) 95.73 kB +0.16% +150 B 🔺
@sentry/browser (incl. Tracing, Replay, Feedback) 108.72 kB +0.14% +149 B 🔺
@sentry/browser (incl. Feedback) 47.04 kB +0.33% +154 B 🔺
@sentry/browser (incl. sendFeedback) 34.57 kB +0.42% +144 B 🔺
@sentry/browser (incl. FeedbackAsync) 39.69 kB +0.37% +143 B 🔺
@sentry/browser (incl. Metrics) 30.53 kB +0.51% +153 B 🔺
@sentry/browser (incl. Logs) 30.82 kB +0.5% +152 B 🔺
@sentry/browser (incl. Metrics & Logs) 31.48 kB +0.47% +147 B 🔺
@sentry/react 31.36 kB +0.53% +165 B 🔺
@sentry/react (incl. Tracing) 53.82 kB +0.29% +153 B 🔺
@sentry/vue 37.51 kB +1.65% +607 B 🔺
@sentry/vue (incl. Tracing) 54.36 kB +0.89% +476 B 🔺
@sentry/svelte 29.54 kB +0.5% +146 B 🔺
CDN Bundle 31.22 kB +0.13% +39 B 🔺
CDN Bundle (incl. Tracing) 51.99 kB +0.08% +41 B 🔺
CDN Bundle (incl. Logs, Metrics) 33.46 kB +0.1% +31 B 🔺
CDN Bundle (incl. Tracing, Logs, Metrics) 53.94 kB +0.1% +49 B 🔺
CDN Bundle (incl. Replay, Logs, Metrics) 74.2 kB +0.07% +49 B 🔺
CDN Bundle (incl. Tracing, Replay) 89.56 kB +0.04% +34 B 🔺
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) 91.54 kB +0.05% +45 B 🔺
CDN Bundle (incl. Tracing, Replay, Feedback) 95.73 kB +0.04% +33 B 🔺
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) 97.73 kB +0.07% +60 B 🔺
CDN Bundle - uncompressed 92.14 kB +0.11% +95 B 🔺
CDN Bundle (incl. Tracing) - uncompressed 154.53 kB +0.07% +95 B 🔺
CDN Bundle (incl. Logs, Metrics) - uncompressed 98.71 kB +0.1% +95 B 🔺
CDN Bundle (incl. Tracing, Logs, Metrics) - uncompressed 160.48 kB +0.06% +95 B 🔺
CDN Bundle (incl. Replay, Logs, Metrics) - uncompressed 228.28 kB +0.05% +95 B 🔺
CDN Bundle (incl. Tracing, Replay) - uncompressed 274.26 kB +0.04% +95 B 🔺
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) - uncompressed 280.2 kB +0.04% +95 B 🔺
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 287.96 kB +0.04% +95 B 🔺
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) - uncompressed 293.89 kB +0.04% +95 B 🔺
@sentry/nextjs (client) 56.32 kB +0.74% +413 B 🔺
@sentry/sveltekit (client) 51.88 kB +0.29% +145 B 🔺
@sentry/core/server 39.99 kB - -
@sentry/core/browser 13.63 kB - -
@sentry/node 144.03 kB +0.01% +8 B 🔺
@sentry/node/import (ESM hook with diagnostics-channel injection) 82.98 kB - -
@sentry/node - without tracing 92.91 kB +0.01% +8 B 🔺
@sentry/node - without channel injection 122.41 kB +0.01% +9 B 🔺
@sentry/aws-serverless 101.17 kB -0.01% -10 B 🔽
@sentry/cloudflare (withSentry) - minified 206.69 kB - -
@sentry/cloudflare (withSentry) 514.13 kB - -

View base workflow run

@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch 2 times, most recently from 54f0ca2 to 0766878 Compare September 24, 2026 18:50
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch from 0766878 to 33c0138 Compare September 24, 2026 19:11
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch from 33c0138 to b00dc56 Compare September 24, 2026 19:59
@logaretm logaretm changed the title feat(nuxt): Register a route provider outside the tracing guard feat(nuxt): Register nuxt route provider Sep 24, 2026
@logaretm

Copy link
Copy Markdown
Member Author

bugbot run

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit b00dc56. Configure here.

Comment thread packages/nuxt/src/runtime/plugins/sentry.client.ts
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch from b00dc56 to 25a1d20 Compare September 24, 2026 21:20
@logaretm
logaretm marked this pull request as ready for review September 24, 2026 21:26
@logaretm
logaretm requested a review from a team as a code owner September 24, 2026 21:26
@logaretm
logaretm requested review from chargome, nicohrubec and s1gr1d and removed request for a team September 24, 2026 21:26
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch 2 times, most recently from 8115c5d to 7aaedb2 Compare September 29, 2026 19:34
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch from 7aaedb2 to 7297f0d Compare September 30, 2026 16:49
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch from 7297f0d to f7a7494 Compare September 30, 2026 16:52
Comment thread packages/nuxt/src/runtime/plugins/sentry.client.ts
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch from f7a7494 to a56d85a Compare September 30, 2026 17:00
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch from a56d85a to 67c088e Compare September 30, 2026 17:02
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch from 67c088e to 6aed389 Compare September 30, 2026 17:09
Nuxt installs the router before its plugins run, so the client plugin can read
it straight off `nuxtApp` rather than waiting for a Vue app the way
`@sentry/vue` does.

Registered outside the `__SENTRY_TRACING__` guard, so route parameterization
survives when tracing is tree-shaken away. Reuses `createVueRouteProvider`
rather than reimplementing the vue-router resolve handling.
@logaretm
logaretm force-pushed the awad/route-provider-nuxt branch from 6aed389 to da27838 Compare September 30, 2026 17:11

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants