Skip to content

Commit 7e3de4f

Browse files
committed
feat: add logs and set field
1 parent bb47eee commit 7e3de4f

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/lib/hooks/useGoogleAnalyticsUserTracking.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,13 @@ const useGoogleAnalyticsUserTracking = () => {
2323
username: currentUser.username,
2424
},
2525
});
26+
gtag('set', { login_status: 'logged_in' });
27+
console.log('hello, user');
28+
} else {
29+
gtag('set', { login_status: 'guest' });
30+
console.log('hello, guest');
2631
}
2732
}, [currentUser]);
2833
};
2934

30-
export default useGoogleAnalyticsUserTracking;
35+
export default useGoogleAnalyticsUserTracking;

0 commit comments

Comments
 (0)