Skip to content

Commit

Permalink
Enable tracking on successfull signups
Browse files Browse the repository at this point in the history
  • Loading branch information
Zishan-7 committed Oct 16, 2024
1 parent 8391ba9 commit 89b1211
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/onboarding/Register.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,6 @@ export default function Register() {
const navigate = useNavigate();

const handleSignUp = async data => {
window._paq.push([
'trackEvent',
'Sign Up',
'Sign Up button clicked',
data.email
]);
if (!isClerkLoaded) return;

try {
Expand Down Expand Up @@ -75,6 +69,12 @@ export default function Register() {
});
if (completeSignUp.status === 'complete') {
await setActive({ session: completeSignUp.createdSessionId });
window._paq.push([
'trackEvent',
'Sign Up',
'Sign Up button clicked',
getValues('email')
]);
navigate('/');
} else {
console.error(JSON.stringify(completeSignUp, null, 2));
Expand Down

0 comments on commit 89b1211

Please sign in to comment.