Skip to content

feat(issues): Add engaged view tracking#107912

Merged
mrduncan merged 8 commits intomasterfrom
mrduncan/engaged-view
Feb 18, 2026
Merged

feat(issues): Add engaged view tracking#107912
mrduncan merged 8 commits intomasterfrom
mrduncan/engaged-view

Conversation

@mrduncan
Copy link
Copy Markdown
Member

@mrduncan mrduncan commented Feb 10, 2026

These events will be fired for issue details views where a user has spent >10s on the page before bouncing.

We track some similar information in https://github.com/getsentry/sentry/blob/master/static/gsApp/hooks/useRouteActivatedHook.tsx#L134-L153 but there are unique differences:

  • This PR will only fire the events if the user is still on the page after 10s, the existing events are fired after 7s or sooner if a user navigates elsewhere.
  • The event in this PR is reusable in the future and we will fire it anywhere we show a significant amount of an issue to a user (ex: if Seer explorer were to show a rich preview)

These events will be fired for issue details views where a user has
spent >10s on the page before bouncing.
@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Feb 10, 2026
scttcper and others added 2 commits February 10, 2026 15:43
Read organization from context inside the engaged-view hook and migrate tests to
renderHookWithProviders so they run with provider state. Use an effect event so
the timer only resets when the viewed group changes while still tracking with
current metadata.

Co-Authored-By: Claude <[email protected]>
Co-authored-by: Cursor <[email protected]>
Align the hook signature with useTrackView by accepting Group and Project
objects instead of primitive IDs. This simplifies call sites and maintains
consistency with other tracking hooks in the codebase.
Copy link
Copy Markdown
Contributor

@cursor cursor bot left a comment

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.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

Update docstring to accurately describe that each 10+ second viewing
session is tracked separately, not once per group per component instance.
@mrduncan mrduncan merged commit be0acf3 into master Feb 18, 2026
61 checks passed
@mrduncan mrduncan deleted the mrduncan/engaged-view branch February 18, 2026 16:27
mchen-sentry pushed a commit that referenced this pull request Feb 24, 2026
These events will be fired for issue details views where a user has
spent >10s on the page before bouncing.

We track some similar information in
https://github.com/getsentry/sentry/blob/master/static/gsApp/hooks/useRouteActivatedHook.tsx#L134-L153
but there are unique differences:
- This PR will only fire the events if the user is still on the page
after 10s, the existing events are fired after 7s or sooner if a user
navigates elsewhere.
- The event in this PR is reusable in the future and we will fire it
anywhere we show a significant amount of an issue to a user (ex: if Seer
explorer were to show a rich preview)

---------

Co-authored-by: Scott Cooper <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: Cursor <[email protected]>
@github-actions github-actions bot locked and limited conversation to collaborators Mar 6, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

claude-code-assisted Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants