Skip to content

feat(vue): Export Vue exception capture helper - #24586

Open
vansh-nagar wants to merge 3 commits into
getsentry:developfrom
vansh-nagar:feat/export-vue-error-handler
Open

vansh-nagar wants to merge 3 commits into
getsentry:developfrom
vansh-nagar:feat/export-vue-error-handler

Conversation

@vansh-nagar

Copy link
Copy Markdown

Exports captureVueException from @sentry/vue together with its ViewModel type. The helper applies the same component metadata and mechanism data as the automatic Vue handler, but captures synchronously so an onErrorCaptured boundary can call it inside withScope without losing per-error scope data across a timer.

The automatic application handler still defers capture to the next event loop and now shares the metadata-building path with the public helper.

Validated with the focused 14-test Vue error-handler suite, the Vue dependency-aware type build, and type-aware package lint.

Fixes #11471

Co-Authored-By: OpenAI/ChatGPT <codex@openai.com>
@vansh-nagar
vansh-nagar marked this pull request as ready for review September 22, 2026 11:45
@vansh-nagar
vansh-nagar requested a review from a team as a code owner September 22, 2026 11:45
@vansh-nagar
vansh-nagar requested review from nicohrubec and s1gr1d and removed request for a team September 22, 2026 11:45

@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 2 potential issues.

Fix All in Cursor

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

Want reviews to match your repository better? Bugbot Learning can learn team-specific rules from PR activity. A team admin can enable Learning in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit f52f52b. Configure here.

Comment thread packages/vue/src/errorhandler.ts
Comment thread packages/vue/test/errorHandler.test.ts
Co-Authored-By: OpenAI Codex <codex@openai.com>
Comment thread packages/vue/src/errorhandler.ts
Co-Authored-By: OpenAI Codex <codex@openai.com>
@github-actions

Copy link
Copy Markdown
Contributor

👋 @nicohrubec, @s1gr1d — Please review this PR when you get a chance!

@Lms24

Lms24 commented Sep 25, 2026

Copy link
Copy Markdown
Member

hey @vansh-nagar thanks for opening this PR! do you need this new helper yourself, or did you pick up the issue because it was still open?

@vansh-nagar

Copy link
Copy Markdown
Author

Thanks for checking. I picked this up because the issue was still open; I do not currently need the helper in my own project. If the use case is no longer something you want to support, I am happy to close it. Otherwise I can adjust the implementation to match the API you would prefer.

@vansh-nagar

Copy link
Copy Markdown
Author

I picked it up because the issue was still open; I do not need the helper for a private project. I verified the requested public export and tests against the current codebase. If the API direction has changed since the issue was opened, I am happy to adjust the PR.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Export @sentry/vue errorHandler

2 participants