What’s new in .NET 8
.NET 8 was released on November 14, 2023 as an LTS (Long Term Support) version, meaning it will continue to receive support, updates, and bug fixes for at least three years from its release date.
As usual, .NET 8 brings support for a new version of the C# languange, namely C# 12. Check out our dedicated page covering what’s new in C# 12.
Let’s dive into the list of changes and new features in .NET 8:
- .NET Aspire (preview)
- .NET SDK changes
- ‘dotnet workload clean’ command
- ‘dotnet publish’ and ‘dotnet pack’ assets
- Serialization
- snake_case and kebab-case JSON naming policies
- Handle missing members during serialization
- Deserialize into read-only properties
- Include non-public properties in serialization
- Add modifiers to existing IJsonTypeInfoResolver instances
- Streaming deserialization: From JSON to AsyncEnumerable
- JsonNode: deep clone, deep copy and other API updates
- Disable default reflection-based serialization
- Add/Remove TypeInfoResolver to existing JsonSerializerOptions instance
- Core .NET libraries
- FrozenDictionary – performance comparison
- Methods for working with randomness – GetItems<T>() and Shuffle<T>()
- Extension libraries
- Garbage collection
- Source generator for configuration binding
- Reflection improvements
- No more reflection: meet UnsafeAccessorAttribute (see performance benchmarks)
- Updating
readonly
fields
- Native AOT support
- Performance improvements
- .NET container images
- .NET on Linux
- Windows Presentation Foundation (WPF)
- Hardware acceleration in RDP
- Open Folder Dialog
- Additional dialog options (ClientGuid, RootDirectory, AddToRecent and CreateTestFile)
- NuGet
One Comment