-
[NA] [FE] Add onboarding analytics tracking with IDs and URL hashing (#3930)
发布于
2025-11-05 13:48:41 +00:00 - [NA] [FE] Add onboarding analytics tracking with IDs and URL hashing
- Add unique id and data-fs-element attributes to all onboarding buttons
- Add source parameter to distinguish quickstart vs onboarding screens
- Add URL hash tracking for onboarding steps (#role, #ai_journey, #start_preference)
- Update PostHog init to capture URL hash in pathname for funnel tracking
- Enable automatic click and page view tracking in PostHog and FullStory
-
Revision 2: Use lodash kebabCase helper for kebab-case conversion
-
Revision 3: Fix ID attribute placement on clickable elements
Move id and data-fs-element attributes from wrapper divs to IntegrationCard
components directly. This ensures analytics tools can capture the IDs when
users click on child elements (text, icons) since the ID is now on the
clickable element itself rather than a non-interactive wrapper.- Revision 4: Manually trigger PostHog pageview for hash changes
URL hash updates via history.replaceState don't trigger PostHog's automatic
pageview tracking. This change manually captures pageview events when the
onboarding step changes, ensuring each step is tracked separately with the
hash included in the URL.-
Use kebabCase everywhere
-
Better check if Posthog is capturing
下载附件