-
Notifications
You must be signed in to change notification settings - Fork 1
feat : GA4 trackedpage 추가 및 click 이벤트 할당 (정준영 part) #219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The head ref may contain hidden characters: "feature/Ga4-trackedpage-\uCD94\uAC00-\uBC0F-click-\uC774\uBCA4\uD2B8-\uD560\uB2F9-\uC815\uC900\uC601"
Changes from 15 commits
e24c89d
bc90ce4
fa83330
b85940f
c9c9fc6
9bb58bf
269cc35
5530b4b
2dba05c
72a66df
434ffc7
b20fe56
950832a
1730734
0f7c186
de086e4
1b317cf
46e208e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,17 +1,22 @@ | ||
| import { useNavigate } from "react-router-dom"; | ||
| import trackClickEvent from "@/utils/trackClickEvent"; | ||
|
|
||
| const RestartButton = () => { | ||
| const navigate = useNavigate(); | ||
| const navigate = useNavigate(); | ||
|
|
||
| const goFirstStep = () => { | ||
| navigate("/mbti-test"); | ||
| } | ||
| const goFirstStep = () => { | ||
| trackClickEvent("/MBTI 테스트 결과", "돌아가기 버튼"); | ||
|
||
| navigate("/mbti-test"); | ||
| }; | ||
|
|
||
| return ( | ||
| <button className="flex justify-center items-center bg-gray-100 rounded-lg w-[72px] h-[60px]" onClick={goFirstStep}> | ||
| <img src="/icon/restart.svg" alt="다시하기 버튼" width={24} height={24} /> | ||
| </button> | ||
| ) | ||
| } | ||
| return ( | ||
| <button | ||
| className="flex h-[60px] w-[72px] items-center justify-center rounded-lg bg-gray-100" | ||
| onClick={goFirstStep} | ||
| > | ||
| <img src="/icon/restart.svg" alt="다시하기 버튼" width={24} height={24} /> | ||
| </button> | ||
| ); | ||
| }; | ||
|
|
||
| export default RestartButton; | ||
| export default RestartButton; | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| import { trackEvent } from "@/libs/analytics"; | ||
|
|
||
| const trackClickEvent = (page: string, element: string) => { | ||
| trackEvent("Click", { | ||
| page: page, | ||
| element: element | ||
| }); | ||
| }; | ||
|
|
||
| export default trackClickEvent; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이부분도 홈, 친구 - 바로 대화하기 인데 다른 것 같습니다.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
넵 수정하겠습니다