-
Notifications
You must be signed in to change notification settings - Fork 10.4k
Open
Labels
DocsThis issue tracks updating documentationThis issue tracks updating documentationarea-blazorIncludes: Blazor, Razor ComponentsIncludes: Blazor, Razor Components
Milestone
Description
PR: #61306.
Released in: 10.0.0-preview4.
Change description
Previously:
NavigationManager.Redirect
in SSR was throwing an internal exception, interrupting the call stack execution.- Consequences: no code after the redirection would be reached and wrapping the redirection call into a try-catch could catch the internal exception, breaking the redirection mechanism.
Currently:
NavigationManager.Redirect
in SSR rises a redirection event that the renderer is subscribed to. Code execution flow is uninterupted.- Consequences: code after redirection is executed.
Fallback to the previous way of working:
AppContext.SetSwitch("Microsoft.AspNetCore.Components.Endpoints.NavigationManager.EnableThrowNavigationException", isEnabled: true);
Metadata
Metadata
Assignees
Labels
DocsThis issue tracks updating documentationThis issue tracks updating documentationarea-blazorIncludes: Blazor, Razor ComponentsIncludes: Blazor, Razor Components