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

[User Feedback] Improve JS example by splitting 'crash report' and 'stand-alone user feedback' use cases #10822

Closed
Tracked by #82252
bruno-garcia opened this issue Jul 24, 2024 · 4 comments · Fixed by #12409

Comments

@bruno-garcia
Copy link
Member

Core or SDK?

Platform/SDK

Which part? Which one?

JS

Description

As reported by a user here:

Our docs currently leads user to capture a feedback by calling first captureMessage to get the event_id.
This is left over from our product capabilities before adding the ability to capture feedback outside an event.

Suggested Solution

I don't believe there's any need to show captureMessage. Since the use cases are 1: On Error, and 2: Stand alone. The message example was a 'work around' used in the past to allow users to capture a feedback stand-alone/outside an error.

We should have 2 snippets, one for each of the following use cases:

  1. Collect a user feedback at any point in time

Show the user how to call captureFeedback passing values.

  1. Collect a user feedback when an error happens.

Similar to how the crash report modal works. Originally documented this using Sentry.lastEventId and a beforeSend snippet that called captureUserFeedback.

@aliu39
Copy link
Member

aliu39 commented Jul 24, 2024

Link to docs: https://docs.sentry.io/platforms/javascript/user-feedback/#user-feedback-api

@aliu39 aliu39 self-assigned this Jul 25, 2024
@bruno-garcia
Copy link
Member Author

Note that we claim that:

Sentry needs the eventId to be able to associate the user feedback to the corresponding event.

This is not longer true since we introduced captureFeedback (it was true for captureUserFeedback) but the docs have the example below without id as "you can add more context` so at no time we say that the id is optional now.

@getsantry
Copy link
Contributor

getsantry bot commented Nov 7, 2024

Routing to @getsentry/product-owners-user-feedback for triage ⏲️

@aliu39
Copy link
Member

aliu39 commented Dec 9, 2024

part of #11635

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants