Xamarin.Forms 2.4.0 Released with .NET Standard 2.0 Support
With help from more than 20 open source community developers, a stable release of Xamarin.Forms 2.4.0 is out, introducing several new features and supporting .NET Standard 2.0 for consistent API usage.
Xamarin.Forms is an open source UI library/framework that allows C# programmers to create native iOS, Android, Windows and macOS apps with Visual Studio and Visual Studio for Mac.
One major feature of the new 2.4.0 release is support for .NET Standard 2.0, which details the set of APIs that all conformant .NET implementations must provide. Its latest version features more than 32,000 of such APIs.
"As support begins to take off for .NET Standard 2.0, we have made sure Xamarin.Forms works seamlessly with both the standard and existing PCL profiles," said David Ortinau in a blog post yesterday. To fully leverage .NET Standard 2.0 APIs, programmers must use Visual Studio 2017 15.3, released last month. Note that the Xamarin.Forms 2.4.0 release notes warn "Not all build features may work" in .NET Standard projects.
Another new addition is an API for feature flags, a setting that programmers can use to enable or disable features. "This will enable you to benefit from features or behaviors that may be of high value to you without introducing changes that you may not want," Ortinau said.
In this initial rollout of feature flags, they only work with what Xamarin calls "fast renderers" for Image, Button and Label controls in Android projects. Fast renderers result from a refactoring of the renderer architecture for performance and memory consumption optimization, doing away with wrapper classes and thus reducing the number of elements in a Xamarin.Forms UI hierarchy.
The 2.4.0 release notes explain more:
This version of Xamarin.Forms includes new Android renderers for Image, Button, and Label, which have been code named "fast renderers". These greatly reduce the render time for these controls, but may also change the behavior of your application if you have created custom renderers or are using third-party controls that override the default renderers. For this release, the default set of renderers will be the legacy renderers to prevent any issues in existing apps, but you may opt in to using the new fast renderers using our new feature flag API.
Also featured is a preview of Xamarin.Forms macOS, fixing bugs discovered in the project's pre-release cycle.
Ortinau thanked "the more than 20 amazing community members that contributed to making this a fantastic release," which he described as " our fastest, most stable release ever."
According to the Xamarin.Forms GitHub site, the overall project to date has benefitted from 79 contributors.
Looking at the Xamarin.Forms roadmap, VNext-previews will be released in the third quarter of this year, with the next stable release set for the fourth quarter.
David Ramel is an editor and writer for Converge360.