ASP.NET Core in .NET 11 Preview 1 Brings New Blazor Components, Improved Navigation, and WebAssembly
Briefly

ASP.NET Core in .NET 11 Preview 1 Brings New Blazor Components, Improved Navigation, and WebAssembly
"The new EnvironmentBoundary component for Blazor allows developers to conditionally render content based on the hosting environment. The component accepts Include and Exclude parameters and works consistently across both Blazor Server and Blazor WebAssembly, removing the need for manual environment checks."
"A new Label component now renders accessible labels with automatic extraction of display names from metadata attributes. It supports both nested and non-nested label-input association patterns. Alongside it, a new DisplayName component provides functionality similar to MVC's @Html.DisplayNameFor() helper, making it easier to display property names from attributes with localization support."
"The NavigationManager.NavigateTo() method and the NavLink component now support relative URI navigation through a new RelativeToCurrentUri parameter. This allows navigation relative to the current page path rather than the application's base URI, which is particularly useful for nested folder structures."
Microsoft released the first preview of ASP.NET Core in .NET 11 with significant enhancements for Blazor, OpenAPI, and web development. The EnvironmentBoundary component enables conditional content rendering based on hosting environment across Blazor Server and WebAssembly. New form components include Label for accessible labels with automatic display name extraction and DisplayName for property name display with localization support. The grid component gained OnRowClick event handling with automatic pointer cursor styling. Navigation improvements include RelativeToCurrentUri parameter support for relative URI navigation and GetUriWithHash() extension method for zero-allocation hash fragment appending. Blazor WebAssembly now supports IHostedService functionality.
Read at InfoQ
Unable to calculate read time
[
|
]