Referring to Why use the full .NET Framework with ASP.NET Core?, it appears .NET 4.7.2 is the way to go forward?
Our existing application targets .NET 4.6.1 using ASP.NET Boilerplate.
Is it mandatory to migrate to .NET 4.7.* in order to leverage ASP.NET Core 2.1 features?
To use .NET Core 2.1 features, you need to target .NET Core 2.1
There is .NET Standard, which is an intersection of features that are available in a range of implementations, including .NET Core and .NET Framework. If you target .NET Standard (some specific version), then you can use the features available in that version of .NET Standard, and it should run on either .NET Framework 4.7.2 or .NET Core 2.1.
As a general guide: libraries (such as Aspnet Boilerplate) should now - where possible - target .NET Standard, but will often have a multi-target build to allow them to internally exploit target-specific features of specific frameworks (perhaps using the enhanced "span" or SIMD capabilities in .NET Core).
Application code should (and must, if it is an executable) target a specific framework such as .NET Framework or .NET Core.
No, it is not necessary to migrate to .NET 4.7.* in order to leverage ASP.NET Core 2.1 features.
ASP.NET Core 2.x is made up of .NET Standard libraries. Apps written with .NET Standard 2.0 run anywhere that .NET Standard 2.0 is supported.
ASP.NET Core 2.x is supported on .NET Framework versions compatible with .NET Standard 2.0:
- .NET Framework 4.7.1 and later is strongly recommended.
- .NET Framework 4.6.1 and later.
You only need to migrate to .NET 4.7.2 if you need features in Announcing .NET Framework 4.7.2:
- ASP.NET – Dependency Injection in WebForms
- ASP.NET – SameSite Cookie
- ClickOnce – Per-monitor support for WPF and HDPI-aware ClickOnce deployed apps
- ClickOnce – Enable SHA256 timestamping of Deployment Manifests
- SQL – Azure AD Universal and Multi-factor Authentication Support
- BCL – Cryptographic Improvements
- BCL – ZLib decompression support to DeflateStream
- BCL – Additional Collection APIs
- WorkflowDesigner High Contrast Improvements
- WPF – Finding ResourceDictionaries by Source
- WPF – Finding ResourceDictionary owners
- WPF – Finding StaticResource references
References:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With