User login with 3rd party services and email/password
If you sign up for a product with Google OAuth and have the associated email registered in the database. Then have a user that wants to login using email/password. What is an elegant way to handle that?
I have seen some services like Medium using a magic link. I think it works like this. The user signs up with Google. Email is set in the database. Then if the user wants to sign in with email a magic link that expires within 15 min is sent to the inbox. There is a token inside the link that I assume when clicked will get the user from the database and log the user in.
Is the magic link and passwordless a good UX?
What are some alternatives that are elegant?
I think another solution is to sign the user in with Google. Then have a step 2 that asks for a username and password. I have seen some services doing this. Thoughts on this approach?
The third thing I can think of is sending a generated password to the users inbox. Then if the user wants to change it he/she can in a profile view. If the user wants to access it at a later date it'll be stored in the inbox.