How to fix "A PackageReference to Microsoft.AspNetCore.App is not necessary when targeting .NET Core 3.0 or higher"

By Tan Lee Published on Feb 18, 2024  606
This post shows you How to fix "A PackageReference to Microsoft.AspNetCore.App is not necessary when targeting .NET Core 3.0 or higher" in ASP.NET Core.
1
2
3
Severity Code Description Project File Line Suppression State
 
Warning NETSDK1080 A PackageReference to Microsoft.AspNetCore.App is not necessary when targeting .NET Core 3.0 or higher. If Microsoft.NET.Sdk.Web is used, the shared framework will be referenced automatically. Otherwise, the PackageReference should be replaced with a FrameworkReference.

Open your Solution Explorer, then click Dependencies =>select Packages and remove Microsoft.AspNetCore.App