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

By FoxLearn 2/18/2024 9:17:05 AM   243
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.
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