-
-
Notifications
You must be signed in to change notification settings - Fork 38
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
Button is calling Microsoft's auth on page load #84
Comments
I think you need to be more accurate when say "Library not working", because it seems more like bug on your side =) Good info to add to issue is:
|
@G4mingEdition thanks for the help man, it solved the same problem here. @alexandrtovmach any ideia if this could be added by default on the lib? |
You not answered to my questions about package version, so I'm not sure about it |
I've added the package version in "Additional information" (1.15.0) |
@alexandrtovmach Thanks again for the package!! Definitely been helpful. I'm also having the same issue after using 1.12.1. If I sign out within my app and revisit the sign in page, microsoft authentication immediately happens without clicking on the button. You have to clear the session store or close the tab and use another tab. Signing out a user (which I tried) doesn't clear the session data and I believe Microsoft said they won't clear the session data. I see that you have a silent login option. It would be good to make this optional as on apps that use several login options, it will automatically force you to sign in with microsoft. I think react-google-login makes this optional. It could also be a security risk on a shared/public machine.
@G4mingEdition @SamuelPinho You might want to avoid clobbering your sessionstorage (since other tools might be setting data in it) and just delete the msal.idtoken. @alexandrtovmach Thanks again!! |
@G4mingEdition .Can I stop the call to authHandler function on page reload? |
@rafenasir just do this after successful authentication
|
Thanks a lot!! :) |
looks like a hacky solution) |
@alexandrtovmach yes!! In the above scenario if I remove the msal.idToken it doesn't show the logout button :) I would highly appreciate if you can come up with a proper solution. |
@alexandrtovmach I pasted the source of the issue here #84 (comment) ... it would be helpful to allow us send a prop to enable or disable this behavior in the useEffect |
Hi @alexandrtovmach , |
Hi,
I have to create a react microsoft login so I used your library but I encoutered a bug.
My code:


I'm using React class components with Redux.
Actual result:


When loading the page, the library is automatically showing the Microsoft's popup and looping "Trying to sign you in"
Then I got this error
Additional information:
Package version : 1.15.0
If I use "withUserData", it's working but it's spamming my API and when I disconnect it's still spamming my API and connecting me again to the website. I'm using "react-facebook-login" and "react-google-login" and I haven't encountered this problem.
Any solution ? 😕
The text was updated successfully, but these errors were encountered: