How to use Dependency Injection correctly for a constructor class with parameters in ASP.NET Core?
Advertisements I have a UserRepository class that has a constructor with several parameters, including EshopContext, IValidateIdService, ICheckNull, and ILogger. I use this class in the UserController class, where I register dependencies in the service container (Dependency Injection container) for IRepository and UserRepository. The problem is that Dependency Injection doesn’t seem to work as I would… Read More How to use Dependency Injection correctly for a constructor class with parameters in ASP.NET Core?