File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed
components/dashboard/src/onboarding Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ import { StepPersonalize } from "./StepPersonalize";
1616import { useUpdateCurrentUserMutation } from "../data/current-user/update-mutation" ;
1717import Alert from "../components/Alert" ;
1818import { useConfetti } from "../contexts/ConfettiContext" ;
19+ import { getGitpodService } from "../service/service" ;
1920
2021// This param is optionally present to force an onboarding flow
2122// Can be used if other conditions aren't true, i.e. if user has already onboarded, but we want to force the flow again
@@ -74,7 +75,19 @@ const UserOnboarding: FunctionComponent<Props> = ({ user }) => {
7475 } ;
7576
7677 try {
78+ // TODO: extract the IDE updating into it's own step, and add a mutation for it once we don't rely on it to consider a user being "onboarded"
79+ // We can do this once we rely on the profile.onboardedTimestamp instead.
7780 const onboardedUser = await updateUser . mutateAsync ( updates ) ;
81+
82+ // TODO: move this into a mutation side effect once we have a specific mutation for updating the IDE (see above TODO)
83+ getGitpodService ( ) . server . trackEvent ( {
84+ event : "ide_configuration_changed" ,
85+ properties : {
86+ ...( onboardedUser . additionalData ?. ideSettings ?? { } ) ,
87+ location : "onboarding" ,
88+ } ,
89+ } ) ;
90+
7891 dropConfetti ( ) ;
7992 setUser ( onboardedUser ) ;
8093
You can’t perform that action at this time.
0 commit comments