-
-
Notifications
You must be signed in to change notification settings - Fork 4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(onboarding): remove welcome page experiment and use new experien…
…ce (#33616) This PR copies the welcome page component from the targeted onboarding flow into the default onboarding flow and removes the TargetedOnboardingWelcomePageExperimentV2 experiment. There are some minor differences to handle the different prop types but everything else is the same.
- Loading branch information
Showing
10 changed files
with
302 additions
and
966 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
642 changes: 115 additions & 527 deletions
642
static/app/views/onboarding/components/welcomeBackground.tsx
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,17 @@ | ||
import {ComponentPropsWithoutRef, useEffect} from 'react'; | ||
import {ComponentPropsWithoutRef} from 'react'; | ||
|
||
import {logExperiment} from 'sentry/utils/analytics'; | ||
import withExperiment from 'sentry/utils/withExperiment'; | ||
import withOrganization from 'sentry/utils/withOrganization'; | ||
|
||
import TargetedOnboarding from './targetedOnboarding/onboarding'; | ||
import Onboarding from './onboarding'; | ||
|
||
type Props = Omit<ComponentPropsWithoutRef<typeof Onboarding>, 'projects'> & { | ||
experimentAssignment: 0 | 1; | ||
logExperiment: () => void; | ||
}; | ||
type Props = Omit<ComponentPropsWithoutRef<typeof Onboarding>, 'projects'>; | ||
|
||
function OnboardingController({experimentAssignment, ...rest}: Props) { | ||
useEffect(() => { | ||
logExperiment({ | ||
key: 'TargetedOnboardingWelcomePageExperimentV2', | ||
organization: rest.organization, | ||
}); | ||
}, []); | ||
if ( | ||
(rest.params.step === 'welcome' && experimentAssignment) || | ||
rest.organization?.experiments.TargetedOnboardingMultiSelectExperiment | ||
) { | ||
function OnboardingController({...rest}: Props) { | ||
if (rest.organization?.experiments.TargetedOnboardingMultiSelectExperiment) { | ||
return <TargetedOnboarding {...rest} />; | ||
} | ||
return <Onboarding {...rest} />; | ||
} | ||
|
||
export default withOrganization( | ||
withExperiment(OnboardingController, { | ||
experiment: 'TargetedOnboardingWelcomePageExperimentV2', | ||
injectLogExperiment: true, | ||
}) | ||
); | ||
export default withOrganization(OnboardingController); |
277 changes: 0 additions & 277 deletions
277
static/app/views/onboarding/targetedOnboarding/components/welcomeBackground.tsx
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.