I have a blazor application, in a page I use the following code to display some sections depending of the current user role.
<AuthorizeView Roles="EditorAdmin">
<Authorized>
<MatIconButton Icon="dashboard" OnClick="@OnClickDashboard"></MatIconButton>
</Authorized>
</AuthorizeView>
On the server, I assign a new role with:
Microsoft.AspNetCore.Identity.UserManager.AddToRoleAsync
But, it has no impact on the UI, I need to logout and then login. I wish to update my UI, but how ?