Describe the bug
The event 'logoutCompleted' for the component mgt-login is not firing.
To Reproduce
Steps to reproduce the behavior:
- Create a new .NET 6.0 application
- Enter the following script in the header section to include the mgt library:
<script src="@("https://unpkg.com/@microsoft/mgt@3/dist/bundle/mgt-loader.js")"></script> (also make sure to that JQuery has been included for the following steps).
- In the Index.html put the following elements to get the "Sign In" button. Make sure to replace the "(YOUR CLIENT ID)" section with the client ID of your app registration in Azure Entra ID:
<mgt-msal2-provider client-id="(YOUR CLIENT ID)"></mgt-msal2-provider>
<mgt-login></mgt-login>
- In the site.js file, put the following code:
$(document).ready(function () {
document.querySelector('mgt-login').addEventListener('logoutCompleted', function () { console.log('Logout Completed!') });
});
- Run the application and sign in. Afterwards sign out again and check the console. No "Logout Completed!" log is visible in the console.
Expected behavior
The 'logoutCompleted' is firing and the "Logout Completed!" message is visible in the console.
Environment (please complete the following information):
- OS: Windows 10
- Browser: Chrome, Firefox, Edge
- Framework: ASP.NET Core, .NET 6.0
- MGT Version: 3.1.3
- Provider: mgt-msal2-provider
Describe the bug
The event 'logoutCompleted' for the component mgt-login is not firing.
To Reproduce
Steps to reproduce the behavior:
<script src="@("https://unpkg.com/@microsoft/mgt@3/dist/bundle/mgt-loader.js")"></script>(also make sure to that JQuery has been included for the following steps).Expected behavior
The 'logoutCompleted' is firing and the "Logout Completed!" message is visible in the console.
Environment (please complete the following information):