Introducing Microsoft .NET 6 | InfoWorld

With the release of .NET 5 last year, Microsoft switched platform development from the .NET Framework 20 years ago to the new cross-platform open source .NET Core. The .NET Framework has moved into maintenance mode, but the new .NET has completed its separation from the Windows release cycle and completes with the new rhythm of the annual release.
In that new rhythm, .NET 5 is called the currently supported release, and .NET 6 in 2021 is intended to be the first long-term supported version of the new platform. This provides three years of support, as opposed to support for .NET 5, which ends in early 2022, three months after the release of .NET 6. The current release can be thought of as a pioneering new feature primarily for developers with regular updates for consumer applications. Long-term support fits better with enterprise product lifecycles and support models.
Enterprise developers are best treated with .NET 5 as a platform to support application migration from the older .NET Framework. It takes a year to start migrating and deploying your application. With the advent of .NET 6 towards the end of 2021, more features and cross-platform support will be enhanced to help you reach your goals. Code built for .NET 5 runs on .NET 6 and can be updated to take advantage of new releases of additional options and APIs.
.NET 6 Preview 1 Highlights
If you want to get started with .NET 6, the first preview release is available. It’s not perfect, but you can try building .NET 6 code with .NET 5. The SDK and runtime can be downloaded from Microsoft’s .NET site and are ready to use with the current preview build of Visual Studio 2019 (Visual Studio 16.9 Preview 4). Or later). There is currently language support for C # 9.0, F # 5.0, and Visual Basic 16.0, and more languages ​​will be supported as the platform evolves throughout 2021. The download includes a runtime for new console and server apps, a runtime for Windows desktop apps, and a runtime for ASP. .NET Core web app. As with previous releases, Windows, Linux, and macOS are supported, and ARM is supported on Windows and Linux in addition to x64.
One of the most important parts of .NET 6 is its position in the .NET cross-platform and integration story, bringing Xamarin to the .NET fold as a key part of the framework rather than an alternative implementation. This allows you to target macOS, Android, and iOS directly from the same code set using the Multiplatform App UI (MAUI) framework under development. This is a continuation of the .NET 5 started process, but far ahead of WebAssembly.
The .NET team is taking an approach that allows them to draw lessons from other parts of the .NET ecosystem. One of these, Hot Reload, is an important element of the Xamarin development model. By allowing code changes to be reflected in the running code, Xamarin developers can test their code without having to go through a complete build cycle. Although not included in the current preview, the team plans to introduce similar functionality in all XAML and C # developments. Treating all your code as if you could test it in the REPL can speed up the development of graphic elements in your app, especially when designing can be an interactive process.
A mix of WebAssembly and desktop
An interesting new feature in .NET 6 is what the team calls the Blazor desktop application. This is an approach that combines the work of .NET 5 WebAssembly with the concept of Electron. The result is a hybrid environment of rich desktop applications that supports Blazor control from .NET code that runs in WebAssembly with hosted web content. The native application container links your Blazor desktop application to system-level services. Interestingly, the Blazor desktop application can also be hosted within the native .NET UI and display elements from a web app in your desktop code.
Electron has proven to be a powerful way to bring web content to your desktop, so when combined with high-performance WebAssembly code, it promises a fast, portable desktop application. The work of the Uno project to bring WinUI 3 controls into WebAssembly can be run as a Blazor desktop application wherever the new runtime is supported, providing an application that can be developed natively with a rich and up-to-date set of controls. Helps to do.
Runtime everywhere
The large number of .NETs does not mean that the application or runtime will be large. As part of the .NET 6 migration, a broader migration to a more configurable SDK will begin. Instead of bundling everything into one SDK, the .Net SDK is increasingly modular and loads only support for the workloads that the code targets. Code running on Windows does not have built-in mobile support. The reverse is also true. Support for these optional workloads not only makes it easier to manage dependencies in your code, but also allows you to serve smaller apps to your users.
As interest in ARM support on Windows grows, .NET 6 improves ARM64 support for key .NET technologies. With the Windows Forms and WPF available on ARM Windows desktops, .NET 6 helps port older .NET apps to ARM devices. The macOS version of .NET 6 also supports Apple Silicon and avoids Rosetta emulation.
Open development
One of the interesting aspects of the .NET 6 development process is that it’s open. Microsoft has chosen to go beyond open development and is using .NET 6 to experiment with new approaches to open design. GitHub is used to host what the development team describes as a theme or epic issue. This is a higher level of the design process than we have ever seen and makes it easier to understand the design choices being made. You can think of a theme as a broader version of a user story, that is, it sets the direction of the product rather than its features.
For example, the .NET 6 theme is “.NET appeals to new developers, students and new engineers”, “.NET is recognized as a compelling framework for building cloud-native apps. Contains statements such as “is”. These are clearly aspirations, but they give enterprise developers and application users a sense of how well their development team is achieving their goals. As a .NET 6 target audience, you need to understand what these themes mean and get Microsoft and the .NET Foundation to follow their underlying promises. It’s important to have an unsurprising and predictable future so that architects can define application development strategies and justify them for both engineering and business management.
As Microsoft continues to develop .NET 6 in public, there’s a lot to look forward to during the rest of 2021. This is just the first preview and we can expect to see more features along with language updates and new tools. .NET 5 is probably the most common migration release, and .NET 6 could become the default .NET platform in the coming years. Early review of both platforms and tools is welcome, but even better is the roadmap and themes being addressed. Now you know where you are heading and what your destination will be.
Copyright © 2021 IDG Communications, Inc.
Introducing Microsoft .NET 6 | InfoWorld
Source link Introducing Microsoft .NET 6 | InfoWorld