Chapter 1 of 8 · 3 practices · 2 min · 3-question quiz
Versions and project setup
Which .NET version to run, and the compiler and package settings that catch bugs before they reach a pull request.
Start: Move to .NET 10 before .NET 8 and 9 go out of support3 practices in this chapter
- 1Move to .NET 10 before .NET 8 and 9 go out of support.NET ships a new major version every November. Even-numbered releases are LTS with three years of support; odd-numbered releases are STS, which Microsoft now supports for two years.
- 2Turn on nullable reference types and treat warnings as errors
NullReferenceExceptionis the most common runtime error in C# code. With nullable reference types enabled, the compiler tracks which references can be null and warns when you dereference one… - 3Manage NuGet versions centrally and lock themIn a solution with several projects, the same package drifts to different versions in each
.csproj. Central Package Management puts every version in oneDirectory.Packages.propsfile, and…
Check yourself on this chapter
3 questions, right here once you are signed in. Your progress is saved as you read.