How to avoid login/sign-up redirection/popup when using AAD B2C from React Application?

AV 86 Reputation points
2022-01-12T12:44:00.557+00:00

Hi,

When using Azure AD B2C with React SPA, can the login redirect/popup be avoided?

I have a business requirement to embed the login/sign-up page in react instead of using MS hosted pages (even if customizable), not show the sign-up/login url to the user for better user experience. Is this possible by using msal react library or any other Microsoft sdk/library?

Thanks.

Microsoft Security | Microsoft Entra | Microsoft Entra External ID
0 comments No comments
{count} votes

Answer accepted by question author
  1. AmanpreetSingh-MSFT 56,956 Reputation points Moderator
    2022-01-13T09:05:03.307+00:00

    Hi @AV • Thank you for reaching out.

    As of now, the only option to avoid login/sign-up redirection/popup is Web application embedded sign-in (as shown below) which uses inline frame element <iframe> to embed a document in an HTML5 web page. However, running MSAL 2.0 in an iframe is not currently supported. Please refer to Configure a single-page application section in the document.

    164667-image.png

    -----------------------------------------------------------------------------------------------------------

    Please "Accept the answer" if the information helped you. This will help us and others in the community as well.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.