This is the fifth article in the recently started series titled Developer Tips, which offers concise hints to enhance productivity. All the articles in this series can be accessed from here.
A label in .NET MAUI is a simple yet powerful View that presents read-only text, like titles, captions, or descriptions.
The Text property holds the string to be displayed and is also bindable.
.NET MAUI All-in-One Templates - Support for NuGet CPM and Nightly Builds
Firstly, .NET MAUI 9 Preview 5 has just been released. The changelog can be found here. Notably, a new Blazor Hybrid Web template has been introduced in this version.
In short, this new template abstracts the Razor components into a distinct Razor Class Library (RCL). Furthermore, it provides the ability to create Blazor Web projects within the same solution and refers to the shared RCL.
The concept of abstracting the Razor components is already facilitated by the Hybrid project templates within the All-in-One template pack.
dotnet new mauiapp -o MyApp -dp Hybrid -rcl
Will review the modifications and cover them in a distinct article.
The year 2024 began with an article outlining the improvements in the Shared Toolkit through the optimization of specifying the Binding as a LINQ expression, without requiring an additional getter or setter.
Mainly, the Binding expression is statically typed, providing better control by aiding in identifying errors during compilation. Furthermore, it preserves the default binding behavior of the View, such as the two-way binding in the case of Entry, enabling editing. This behavior can be modified using the BindingMode parameter.
Abstracts the Shared components as a separate .NET MAUI Class Library
As we all know .NET MAUI is an evolution of Xamarin.Forms. The underlying architecture transitioned from Renderers to Handlers. The project structure is unified. But for the projects that are getting migrated and developers coming from Xamarin.Forms background would feel at home with the classic multi-project solution structure.
To effectively support this, the All-in-One project templates introduced an option to abstract the Shared components as a separate .NET MAUI Class Library.
The topic for this June monthās .NET MAUI community standup is VS Code Updates.
Of late, VS Code has incorporated many new features, such as XAML IntelliSense and Hot Reload, as the end of support for VS for Mac is quickly approaching (Aug 31, 2024).
Update: The community links for this monthās standup are here.
David highlighted using MAUI Nightly Builds in the standup. Projects in the All-in-One templates pack already support utilizing the Nightly builds from version 4.6 onwards. However, setting up the package source from the CI feed involves a few manual steps as detailed in the earlier article.
But, automation is the need of the hour. The upcoming release of templates pack v5.6, scheduled for this week, will streamline the process by eliminating manual steps, ensuring seamless functionality when selecting the Nightly builds option upon project creation. Cool š.
Update: v5.6 has just been released. Consult this article for further details.
Remember to join live on Thu, Jun 6 at 17:00 UTC. Click the link to access the timing in your local/preferred time zone. Note, itās back at the same time.
Happy coding. Stay connected as we continue to learn and share the experiences from this exciting journey of being a .NET developer.
.NET MAUI Project File - Base TFM and Conditional OutputType
The topic for this monthās .NET MAUI community standup is so interesting, Testing your MAUI Apps ft. Gerald Versluis.
Remember to join live on Thu, Apr 4 at 17:00 UTC. Click the link to access the timing in your local/preferred time zone. Note, it’s back at the same time.
Update: The community links for this month’s standup are here.
The All-in-One .NET MAUI App templates support this feature out of the box by incorporating the base framework TFM and conditionally configuring the OutputType property š.
.NET MAUI Project File – Base TFM and Conditional OutputType
dotnet new mauiapp -o MyApp
Happy coding. Stay connected as we continue to learn and share the experiences from this exciting journey of being a .NET developer.
This is the second article in the newly started series titled Developer Tips, which offers concise hints to enhance productivity. The inaugural article is about Margin and Padding. All the articles in this series can be accessed fromĀ here.
The BindableLayout functions as an item repeater, enabling an ILayout to interact with a data-bound IEnumerable.
Starting a new series titled Developer Tips which offers small hints to enhance developer productivity. All the articles in this series can be accessed fromĀ here.
We’ll start with the Margin and Padding that effectively position the View.
Both the properties have been appropriately defined at the View level and are of the type Thickness, which is a structure that defines 4 important properties: Left, Top, Right, and Bottom.
This article provides a comprehensive guide on leveraging the Maps feature from the .NET MAUI Community Toolkit in a WinUI 3 App through the robust Embedding feature.
The CommunityToolkit.Maui.Maps NuGet package provides access to Bing Maps through a WebView on Windows. The Handler definitions for the Windows platform for the .NET MAUI Maps feature are hosted in this package.
To ensure the Maps feature functions correctly on the native WinUI 3 App, it is imperative to slightly adjust the feature initialization in the MAUI pipeline.