fix #659: advance after new user onboarding#670
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
shashilo
approved these changes
Nov 7, 2025
alexappleget
approved these changes
Nov 7, 2025
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Before:
A new user wasn't able to complete the onboarding form. They would remain on the last page of the form after clicking Find My Perfect Gift.
After:
Middleware was preventing the user from navigating to the
/dashboardpage when submitting the form. On submit,router.push('/dashboard')gets called. The middleware detects this as the user not being on the/onboardingpage, which then redirects them back to/onboarding.Adds new query parameters to
router.push('/dashboard?onboardingCompleted=true')which gets detected by a newifstatement in the middleware, which detects that a user has completed onboarding for the first time, then correctly redirects them to the/dashboard.Also added
use clientto theOnboardingcomponent since it doesn't seem like it should be a server component.Closes #659
Additional information
This form is a component located in
app/onboarding/onboarding-form.tsx. If it'll be a client side component, it should eventually be moved into thecomponentsfolder.Pre-submission checklist
test #001: created unit test for __ component)Peer Code ReviewersandSenior+ Code Reviewersgroupsgis-code-questions