-
-
Notifications
You must be signed in to change notification settings - Fork 115
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
feat(authentication): support sign-in with redirect on Web #238
Conversation
@lincolnthree You can give it a try if you want:
Would be glad if you give feedback. |
Thanks @robingenz, I will try this! |
@lincolnthree Have you already had the chance to test it? |
@robingenz Apologies. I have had a crazy few weeks. I haven't had a chance to test this yet. Is there a nightly build I can try? |
Out of curiosity, have you tried this yourself? Given the fact that (as I understand it) Unless the firebase API has changed or I am not understanding it, it should block forever and never return (and the page will redirect, cancelling the script). Or... are you already handling this scenario and passing the authenticated user via This is the relevant example from the Firebase docs:
|
I don't know what I did there, half of the code is missing. 😆 |
@lincolnthree I fixed and tested it and published a new version:
The |
@robingenz Haha yeah, it happens, and awesome! I will try this today or tomorrow. Sorry for the wait. Crazy week. |
One thing I'm curious about. How are error codes reported with this? It looks like it would just be an unhandled exception, or possibly be swallowed entirely, right? Also, perhaps users should have some control over when the redirect result is checked, so it doesn't always get called if unnecessary? Maybe Just thinking out loud. https://firebase.google.com/docs/reference/js/v8/firebase.auth.Auth#getredirectresult |
You are right. I improve that. |
@lincolnthree I have implemented and tested your suggestions and am much happier with the new solution. Thanks for your ideas! Here's a dev version in case you want to try it out as well:
I merge this PR in a timely manner. |
Pull request checklist
Please check if your PR fulfills the following requirements:
npm run changeset
).Close #224