32
TOP 5 .NET MAUI new features🏅
Microsoft has already started publishing .NET MAUI Previews these days. They show some exciting new features that will greatly reduce time and improve performance when programming.
In case you don’t know what .NET MAUI is, it’s the evolution of Xamarin.Forms, extended from mobile to desktop scenarios, with UI controls rebuilt from scratch for performance and extensibility.
.NET Hot Reload is a new feature, which according to Microsoft, will allow you to make live edits to the source code of your .NET MAUI application while it is running, reducing the number of times you need to rebuild your application.
They also tell us that in the next versions .NET Hot Reload will also be available for Android, iOS and macOS, and will also integrate XAML Hot Reload and Live Visual Tree.
The new BlazorWebView lets you host a Blazor web application directly in your .NET MAUI application and take advantage of native platform functionality and user interface controls. The control can be added to any XAML page and pointed to the root of the Blazor application.
<BlazorWebView
HostPage="wwwroot/index.html"
Services="{StaticResource Services}">
<BlazorWebView.RootComponent>
<RootComponent
Selector="#app"
ComponentType="{x:Type local:Main}"
/>
</BlazorWebView.RootComponent>
</BlazorWebView>
Also .NET MAUI will have a function to migrate a custom renderer from Xamarin.Forms. Although these can be used with some compatibility package, Microsoft claims that this will help the application to be much lighter and to develop it much more efficient.
dotnet build -t:Run -f net6.0-android
dotnet build -t:Run -f net6.0-ios
dotnet build -t:Run -f net6.0-maccatalyst
On mobile platforms especially you want your first screen to appear as quickly as possible, and this is done by implementing a static splash screen. .NET MAUI now has a single place to describe your splash screen for all platforms that support them.
As Microsoft tells us, .NET MAUI will come with a unification of critical libraries. You will provide several benefits by merging the Xamarin.Essentials library into the .NET MAUI so that with these, you can easily use the device’s capabilities such as device sensors, photos, contacts, and many services that you use on a regular basis, such as authentication and secure storage.
- .NET MAUI at the time managed to have feature-parity (equality of characteristics) and achieve much better performance (than it already has in itself) than it has today to develop Android applications, iOS, UWP and other platforms.
- In addition, we will not have to worry about having to implement complex Handlers or the cross-platform appearance that we really need to do, which we would end up doing (if it were the case) at a native level using the same APIs of the mobile platforms.
.NET MAUI has only a few months left to go officially. The latest features mentioned by Microsoft in the Previews are very powerful. At the moment we still have a little left to have it and apparently it will greatly facilitate developers to program web, console or mobile applications.
What do you think?🤔
32