Untitled
unknown
razor
3 years ago
1.2 kB
22
No Index
<CascadingAuthenticationState> <NotificationComponent> <Router AppAssembly="@typeof(Program).Assembly"> <Found Context="routeData"> <AuthorizeRouteView RouteData="@routeData" DefaultLayout="@typeof(MainLayout)"> <NotAuthorized> @if (!context.User.Identity.IsAuthenticated) { <RedirectToLogin /> } else { <p> You are not authorized to access this resource. </p> } </NotAuthorized> </AuthorizeRouteView> </Found> <NotFound> <LayoutView Layout="@typeof(MainLayout)"> <p>Sorry, there's nothing at this address.</p> </LayoutView> </NotFound> </Router> </NotificationComponent> </CascadingAuthenticationState>
Editor is loading...