Using Visual Studio 2019 I installed AutoMapper version 8.1.0 via NuGet. When I try to add the services.AddAutoMapper()
call though in my Startup.cs
file I get a compiler error that the method doesn't exist.
I've already tried to do a dotnet clean
and dotnet restore
from the NuGet console but that didn't help.
It is an old thread, however the solution for this problem is to install Automapper.Extensions.Microsoft.DependencyInjection
package along with your automapper
package.
I hope it helps.