[Reduced Onboarding] Add avatar metric (#3999)

* Add prop to finished event

* Fix type

* Use separate event
This commit is contained in:
Eric Bailey
2024-05-13 16:46:22 -05:00
committed by GitHub
parent 5e7a89577d
commit 93843045e2
3 changed files with 12 additions and 1 deletions
+3
View File
@@ -53,6 +53,9 @@ export type LogEvents = {
'onboarding:moderation:nextPressed': {}
'onboarding:profile:nextPressed': {}
'onboarding:finished:nextPressed': {}
'onboarding:finished:avatarResult': {
avatarResult: 'default' | 'created' | 'uploaded'
}
'home:feedDisplayed': {
feedUrl: string
feedType: string
+8
View File
@@ -134,6 +134,14 @@ export function StepFinished() {
return existing
})
}
logEvent('onboarding:finished:avatarResult', {
avatarResult: profileStepResults.isCreatedAvatar
? 'created'
: profileStepResults.image
? 'uploaded'
: 'default',
})
})(),
])
} catch (e: any) {
+1 -1
View File
@@ -84,7 +84,7 @@ export type OnboardingAction =
imageMime: string
creatorState?: {
emoji: Emoji
backgroundColor: string
backgroundColor: AvatarColor
}
}