question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Deprecate react-aad-msal in favor of the upcoming official @azure/msal-react library

See original GitHub issue

Hey folks,

Thanks for everyone’s patience, and I apologize for the late replies. Since July a small group has been working to redesign the react-aad-msal library from ground-up to work with MSAL 2.0 using the @azure/msal-browser package. We had hoped to have an initial release in August, then roll out in a few production apps through the end of the month. However, with life, covid, and some developments in MSAL, these timelines had to undergo a lot of change to make sure things were tackled correctly.

In July members of the MSAL team reached out to let us know they were planning to build out an official React library soon, and wanted to take the opportunity of the hackathon to work together and develop an architecture. During this time we were able to test out @azure/msal-browser, and identified a number of API changes that everyone felt would unblock an official React wrapper. The more substantial of these architectural changes related to an event API whereby external libraries can subscribe to internal MSAL data and events in order for React to become aware of changes in internal state. I’m happy to hear that this work is underway at the moment, and the contract of what that API looks like is nearing the review stage.

In lieu of the changes to the underlying @azure/msal-browser, it didn’t make much sense to release an update to react-aad-msal since the contracts weren’t yet in place. The API changes will dramatically simplify how we build out a wrapper library, and at which point it should be pretty simple to develop the official @azure/msal-react library, and there isn’t much of a need for react-aad-msal. From this standpoint, react-aad-msal is gearing up to be deprecated in the near future, and I will be working on some migration guides to get people moved over easily.

In the interim before the official react-msal is released, and now that the designs and contracts are nearly finished, I am hoping to get some time in the next few weekends to build a basic update to react-aad-msal that gets people shifted from msal to @azure/msal-browser. These changes would be substantial, although we would be targeting a very similar architecture to @azure/msal-react when it finally releases. After this point, the plan is to deprecate react-aad-msal and work to help folks move to the officially supported library.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:8
  • Comments:8 (1 by maintainers)

github_iconTop GitHub Comments

11reactions
jasonnuttercommented, Nov 12, 2020

Excited to announce that the first alpha of MSAL React is now available! https://github.com/AzureAD/microsoft-authentication-library-for-js/releases/tag/msal-react-v1.0.0-alpha.0

Please try it out and let us know if you have feedback. We will be putting together a migration guide for react-aad-msal before public preview.

Worth to mention though, that for B2C authentication it is (@azure/msal-browser) not recommended for production yet, due to “some outstanding bugs”.

B2C is now supported in MSAL Browser v2 (which MSAL React relies on).

3reactions
tleclairecommented, Oct 8, 2020

Is this new library anywhere available already?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Reactjs with Azure Ouath - Stack Overflow
Microsoft is currently in process of building an official @azure/msal-react library which will replace react-aad-msal.
Read more >
@azure/msal-react - npm
The MSAL library for JavaScript enables client-side JavaScript applications to authenticate users using Azure AD work and school accounts (AAD), ...
Read more >
Tutorial: Create a React single-page app that uses auth code ...
The SPA you build uses the Microsoft Authentication Library (MSAL) for React. In this tutorial: Create a React project with npm ...
Read more >
msal js
Microsoft Authentication Library (MSAL) for Javascript enables client-side web ... an official @azure/msal-react library which will replace react-aad-msal.
Read more >
Calling Microsoft Graph using @azure/msal-react from PCF ...
The announcement of Microsoft's own official MSAL React library is ... With this, they introduced a new npm package @azure/msal-browser ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found