ASP.NET Core 2.0 Features: What’s New, Fascinating and Significant?
Microsoft made available ASP.NET Core 2.0 as a final release on August 14, 2017. In today’s post we would take a look at the newly introduced features as mentioned below but the list is not exhaustive.
Razor Pages
Now coding page-focused scenarios will be easier and more productive at the same time with the newly introduced feature Razor Pages.
Razor is a markup syntax which enables to embed server based code into web pages. It consists of HTML, C# and Razor markup. The files which contain Razor usually ends with .cshtml extension.
ASP.NET Core metapackage
The earlier version ASP.NET Core came with an increased modularity but it had a downside that is ASP.NET specialists had to find and depend on a relatively large number of smaller packages. This has been addressed in the latest version ASP.NET Core 2 by introducing Microsoft.AspNetCore.All package.
Microsoft.AspNetCore.All package is a metapackage and it references to the following packages:
All ASP.NET Core packages.
All Entity Framework Core packages.
All dependencies used by ASP.NET Core and Entity Framework Core
Runtime store
If your applications use the Microsoft.AspNetCore.All metapackage then it can leverage the new .NET Core Runtime Store by default. All the runtime assets required to run ASP.NET Core 2.0 applications are included in the Store. In order to enhance application startup time, the assets in the Store are precompiled.
In other words, if you are using Microsoft.AspNetCore.All then automatically your published app will be smaller in size and with faster startup.
Improvements in Kestrel web server
New features have been introduced in the Kestrel web server; these features enrich it as an Internet-facing server. Also a number of server constraint configurations options have been added for the new property Limits for the class KestrelServerOptions.
Now you would be able to add limits for the following:
Minimum request body data rate
Maximum request body size
Maximum client connections
WebHost builder APIs
The WebHost builder APIs are basically static methods within the Microsoft.AspNetCore.All package which offers you various ways to create and start a WebHost with default configuration. This feature has been introduced in order to reduce the common code which is required by most of the ASP.NET Core applications.
Tag helper components
You can use the Tag Helper components either to generate or modify a specific block of HTML. The head and body of a page can be modified by using HeadTagHelper and BodyTagHelper by which all the registered tag helper components will be run.
Logging update
In the latest version, by default logging is integrated into the dependency injection (DI) system. You have to add providers and configure filtering in the Program.cs file and not the startup.cs file.
What’s your say on ASP.NET Core 2.0?
This list is not exhaustive! Did you try this latest version? Which features fascinated you the most? We would love to know your views. Please be the first to leave your comments below; you can also start a conversation here.










