报错Package Microsoft.AspNetCore.Authentication.JwtBearer 5.0.2 is not compatible with netcoreapp3.1解决

在使用.NET Core Web API引入JwtBearer时出现这个错误,.NET Core版本是3.1
解决方法是:导入版本低于3.1.11的JwtBearer,亲测有效

dotnet add package Microsoft.AspNetCore.Authentication.JwtBearer -v 3.1.10

原文地址:https://www.cnblogs.com/liuliang1999/p/14362415.html