News

Unifying .NET with .NET Standard 2.0

The goal of .NET Standard is for "one library to rule them all," or more simply, one library of APIs that can be used across a number of platforms without much afterthought. The .NET team lets us in on their plans in the near future.

The .NET convergence is getting nearer to a reality, as Microsoft's .NET team publishes its plans for upcoming versions of .NET Standard, a master library of APIs.

".NET Standard solves the code sharing problem for .NET developers across all platforms by bringing all the APIs that you expect and love across the environments that you need: desktop applications, mobile apps & games, and cloud services," writes Microsoft's Immo Landwerth, in a blog post.

Currently, developers targeting one of the .NET variants had to understand how APIs being used in an app would interact with the base class library for the targeted .NET. With .NET Standard, developers won't have to give API compatibility much thought other than which API to use. At least that's the goal. Developers who have developed for Windows Phone 8.0 platforms have already gotten a taste of .NET Standard 1.0, and other versions already exist for differing versions of .NET platforms (.NET Core 1.6, all versions of .NET Framework 4.5 and newer, and Universal Windows Platform 10.0).

Version 2.0 of .NET Standard will be made available when the next versions of .NET Core, .NET Framework, Xamarin.iOS, Xamarin.Android, and UWP are shipped. Landwerth notes that even with 2.0 coming, compatibility issues are still a concern. .NET Standard 2.0 will be compatible with Portable Class Libraries, but he said the team will make a compatibility shim available so .NET Standard-based libraries can be referenced in .NET Framework binaries.

Landwerth suggests that developers start to use .NET Standard rather than PCLs: "The tooling for targeting .NET Standard 2.0 will ship in the same timeframe as the upcoming release of Visual Studio, code-named "Dev 15". You'll reference .NET Standard as a NuGet package. It will have first class support from Visual Studio, VS Code as well as Xamarin Studio."


About the Author

Michael Domingo is a long-time software publishing veteran, having started up and managed several developer publications for the Clipper compiler, Microsoft Access, and Visual Basic. He's also managed IT pubs for 1105 Media, including Microsoft Certified Professional Magazine and Virtualization Review before landing his current gig as Visual Studio Magazine Editor in Chief. Besides his publishing life, he's a professional photographer, whose work can be found by Googling domingophoto.

comments powered by Disqus

Featured

Subscribe on YouTube