I'm trying to update MSAL Angular v1 to v2 now, but have had some problems. One of them is that BroadcastService is missing in V2.
I have followed this guide, but none mentions what an equivalent of BroadcastService is in V2. https://github.com/AzureAD/microsoft-authentication-library-for-js/blob/dev/lib/msal-angular/docs/v2-docs/v1-v2-upgrade-guide.md
I found MsalBroadcastService in V2 repository, but not sure how to migrate it.
https://github.com/AzureAD/microsoft-authentication-library-for-js/blob/b315d95797810241224a3cf118e67a1a723adec7/lib/msal-angular/src/msal.broadcast.service.ts#L13
My current code is something like this.
this.broadcastService.subscribe("msal:loginFailure", payload => {
// do something here
});
this.broadcastService.subscribe("msal:loginSuccess", payload => {
// do something here
});