Skip to content

🐸 Rybbit - open-source and privacy-friendly alternative to Google Analytics that is 10x more intuitive.

Update SignupPageContent to track user referral source with identification

Bill Yanga196146096fc
diff --git a/client/src/app/signup/page.tsx b/client/src/app/signup/page.tsx
index 78f35bc10..13106a368 100644
--- a/client/src/app/signup/page.tsx
+++ b/client/src/app/signup/page.tsx
@@ -141,8 +141,10 @@ function SignupPageContent() {
setOrganizationId(data.id);
// Track how user found Rybbit
- if (IS_CLOUD && referralSource) {
- window.rybbit?.event("found", { via: referralSource });
+ if (IS_CLOUD && referralSource && userStore.getState().user?.id) {
+ window.rybbit?.identify(userStore.getState().user?.id || "", {
+ source: referralSource,
+ });
}
setCurrentStep(3);