Migrating Mvc Dependency Injection

Migrates dependency injection configuration from ASP.NET Framework MVC and WebAPI projects to ASP.NET Core built-in DI or modernized third-party container integration. Use when upgrading projects that use DependencyResolver.SetResolver, config.DependencyResolver, custom IControllerFactory, custom IHttpControllerActivator, ServiceLocator.Current, or third-party containers (Autofac, Unity, Ninject, Castle Windsor). Also triggers for "migrate dependency injection", "convert DI container", "replace DependencyResolver", PerRequest lifetime mapping, IControllerActivator migration, and property injection patterns.

Microsoft 2051fb2 10.5 KB Updated 2.7k repo stars

File contents

microsoft/upgrade-agent-plugins/tree/main/plugins/upgrade-agent/upgrade/dotnet/skills/lazy/web/mvc/migrating-mvc-dependency-injection commit 2051fb2a9b

Frequently asked questions

npx skillmds@latest add microsoft/migrating-mvc-dependency-injection