Welcome to another busy week! Here's what we have in store this Monday morning:
- One big thing: .NET 6 Preview 5 has arrived
- The little things: Visual Studio 2022 Preview 1 has arrived, dropping support for older frameworks, Markdown tables extension
- Last week in the .NET world
One big thing: .NET 6 Preview 5 has arrived
Even though it still seems that we're still recovering from Preview 4 announced around Build, it's about that time: .NET 6 Preview 5 arrived last Thursday. While Preview 4 brought a lot of developer productivity and experience features like Minimal APIs and Blazor WebAssembly AOT, Preview 5 is a jam-packed release with a lot of work going towards unification in .NET 6.
A big part of that is SDK workloads—announced in Preview 4— a new .NET SDK feature that enables the .NET team to add support for new application types without increasing the size of the SDK. For example, you may want to include MAUI or Blazor WebAssembly application types as you need them. You can view SDK workloads as a package manager for the .NET SDK—the emphasis on the SDK, as Microsoft's vision of one SDK is coming together.
On top of that, Preview 5 brings NuGet package validation, a lot more Roslyn analyzers, improvements to the Microsoft.Extensions
APIs, a new JSON source generator, WebSocket compression, OpenTelemetry support, and much more. What about ASP.NET Core? Hot Reload is enabled by default, improvements to Blazor WebAssembly download size with runtime relinking, faster gets and sets for HTTP headers, and more.
With EF Core, Preview 5 brings the first iteration of compiled models. Much like Blazor WebAssembly ahead-of-time (AOT) compilation, the compiled models functionality addresses increasing your startup time. As Jeremy Likness notes: "If startup time for your application is important and your EF Core model contains hundreds or thousands of entities, properties, and relationships, this is one release you don’t want to ignore."
The EF team is reporting 10_x_ performance gains using compiled models. How does this work? When EF creates a context, it creates and compiles delegates to set the table properties. This gives you the ability to query properties right away. Using lazy initialization, EF Core only is accessed when needed. You'll want to check out the blog post for an in-depth discussion of all that's involved. While a fast startup time won't get any complaints, keep in mind that global query filters, lazy loading proxies, change tracking proxies, and IModelCacheKeyFactory
implementations aren't supported yet.
If mobile/desktop development is your jam, you'll also want to check out MAUI updates for Preview 5.
The little things: Visual Studio 2022 Preview 1 is here, dropping support for older frameworks, Markdown tables extension
After much fanfare about 64-bit support, Visual Studio 2022 Preview 1 is now here and available for you to try out. By all accounts, it seems to be smooth and snappy—you know, as it should be—and can be installed with earlier versions of Visual Studio. You can check out the Visual Studio 2022 roadmap to see what's coming next.
The 64 bits are getting most of the buzz, but you also may have missed support for IntelliCode completions. These updates complete code for you, sometimes even whole lines of code. Based on your context, it'll predict the next part of code to write, and gives you the option to Tab
to accept the changes. Mark Wilson-Thomas mentions this is done by combining a "rich knowledge of your coding context" and also a transformer model that is trained on around half a million public open-source GitHub repositories.
Here's a quick example of me testing it out:
In another example, I wrote a function to print out the first name and last name—it suggested I concatenated the strings together. (I would have preferred string interpolation, but I digress.) Then, as I did a WriteLine
call, it suggested I use the method I just wrote.
The .NET team is embarking on an effort to drop older framework versions. While dropping frameworks can be a breaking change, building for every framework version increases complexity and size. The team worked around this by harvesting—building for current frameworks but downloading a package's earlier version and harvest binaries for earlier frameworks. This allows you to update without the worry of losing a framework version, but you won't get any fixes or features from these binaries.
Starting with .NET 6 Preview 5, the .NET team will no longer harvest to ensure support for all assets. This means they are dropping support for frameworks older than .NET Framework 4.6.1, .NET Core 3.1, and .NET Standard 2.0.
If you’re currently referencing an impacted package from an earlier framework, you’ll no longer be able to update the referenced package to a later version. Your choice is to either retarget your project to a later framework version or not updating the referenced package (which is generally not a huge take back because you’re already consuming a frozen binary anyways).
Here's something I learned this week: there's a Markdown Tables extension in Visual Studio Code. Who do I talk to about refunding all my time spent tweaking Markdown tables?
🌎 Last week in the .NET world
It's another busy week with new preview releases for .NET and Visual Studio.
🔥 The Top 5
- .NET 6 Preview 5 is out: Richard Lander announces it, Daniel Roth writes about ASP.NET Core updates, Jeremy Likness covers EF Core, and David Ortinau covers .NET MAUI.
- Visual Studio 2022 Preview 1 is now available, and so is 2019 16.11 Preview 2.
- David Pine writes about building SPAs with Blazor.
- Matthew MacDonald writes about the new VS Code Remote Repositories extension.
- Charlin Agramonte explores drag-and-drop in Xamarin.
📢 Announcements
- Scott Hanselman introduces dotnet repl.
- Mika Dumont shares what's new with Roslyn.
- The Uno Platform introduces the 3.8 release.
đź“… Community and events
- The next .NET Conf, on July 29, will have an F# focus.
- Jon Skeet has a new book.
- The .NET Docs Show talks to Konrad Kokosa.
- For community standups: Tooling previews Hot Reload for WinForms and WPF, Entity Framework discusses Azure Cosmos DB and EF Core, and ASP.NET builds Teams apps using Blazor.
🌎 Web development
- Mahesh Sabnis works with state management in Blazor apps.
- Jignesh Trivedi works on event handling in Blazor.
- Dave Brock updates a Blazor WebAssembly app from .NET 5 to .NET 6 and writes about REST API versioning in ASP.NET Core.
- Marinko Spasojevic uses Dapper with ASP.NET Core Web API.
- Matthew Jones continues his Solitaire in Blazor series.
🥅 The .NET platform
- Ben Watson writes about Bing migrating their Workflow Engine to .NET 5.
- David Ramel writes about Project Reunion updates.
- Richard Lander mediates a conversation about networking and diagnostics.
- Adam Storr sets content for HttpClient testing with JSON.NET and System.Text.Json.
- Daniel Gomez Jaramillo writes about hot reload for .NET developers.
- Varun Setia describes a new programming model for handling JSON in .NET 6.
- Thomas Ardal shows a name and profile photo with .NET and Gravatar.
- Patrick Smacchia logically names embedded resources in a .csproj file.
- Rick Strahl runs .NET Core apps on a framework other than a compiled version.
â›… The cloud
- David Ramel writes about .NET 6 support on Azure Functions.
- John Reilly works with Azure Functions and .NET 5.
- Davide Bellone compares queues and topics in Azure Service Bus.
- Hugo G Fernandez R creates a RESTful API with automatic documentation on Azure App Service.
đź“” Languages
- Khalid Abuhakmeh writes about C# pattern matching.
- Niels Rasmussen goes deep on record structs in C# 10.
🔧 Tools
- Mitchel Sellers works on DI, async, and HangFire for background processing.
- David Ramel writes about C# scripting.
- Mark Wilson-Thomas writes about IntelliCode completions in Visual Studio.
🏗 Design, testing, and best practices
- Steve Smith writes about prioritizing and microservices.
- Derek Comartin talks about leveraging event-driven architecture for the real-time web.
- David Adsit compares TDD and BDD.
- Anwar Al Jahwari writes about the Interface Segregation Principle.
🎤 Podcasts
- .NET Rocks talks about open source in the enterprise.
- The .NET Core Podcast discusses greenfield and brownfield in .NET with Harry Bellamy.
🎥 Videos
- On .NET discusses clustering in Orleans, works with Azure AD B2C in ASP.NET, talks about using Blazor with Tailwind CSS, gets started with Azure Static Web Apps, and talks about the null coalescing operator in C#.
- Visual Studio Toolbox continues a discussion on async debugging.
Top comments (0)