-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Use wpcc onboarding flow for account creation during oauth login by default #83026
Conversation
Here is how your PR affects size of JS and CSS bundles shipped to the user's browser: App Entrypoints (~12 bytes added 📈 [gzipped])
Common code that is always downloaded and parsed every time the app is loaded, no matter which route is used. Sections (~22 bytes added 📈 [gzipped])
Sections contain code specific for a given set of routes. Is downloaded and parsed only when a particular route is navigated to. Async-loaded Components (~23 bytes added 📈 [gzipped])
React components that are loaded lazily, when a certain part of UI is displayed for the first time. Legend What is parsed and gzip size?Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory. Generated by performance advisor bot at iscalypsofastyet.com. |
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.
It's working as expected on the Calypso private site link, vaultpress.com and WooCommerce login.
Nice fix @lsl!
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.
I tested and added unit tests as I went. Looks good to me! Please feel free to edit the tests! 👍
de8acf5
to
1f67936
Compare
} ); | ||
return `${ signupUrl }/${ signupFlow }?${ params.toString() }`; | ||
} | ||
return `${ signupUrl }/${ signupFlow }`; |
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.
Moved signupFlow down to here, maintaining redirectTo pass through for consistency, I can't actually see anything that uses it other than 3-4 instances in trunk that are only using it to bypass /start (they're setting signup_flow to account i.e. what we would return with the redirect_to anyway.)
@eoigal do you mind taking a look re the highlander comment login pathing through here? |
Worked for me testing an OAuth2 app. This PR directs the signup through a user-only flow (that is, no site is created). The use case I'm looking at is for an app that doesn't make sense to use unless the user has at least one site, but I think that's a separate issue. Thanks for fixing! |
These are the use cases I'm worried about as we'll more or less be breaking them with this change. They should be fixable by passing in a |
Fixes #71027
Proposed Changes
There are two issues being resolved here:
signupUrl
Todo:
Could use help testing
Testing Instructions
Redirect to & /start/account handling:
Wpcc login paths:
https://wordpress.com/log-in?client_id=930&redirect_to=https%......
wordpress.com
part tocalypso.localhost:3000
for testing.