For an ASP.NET MVC5 application I have created a ModelBinderProvider for a certain type of data.
If I add the new ModelBinderProvider to the BinderProviders collection in the Global.asax it works perfectly.
In the application I am using Autofac as IoC which allows me to register for example my custom ModelBinders:
Autofac.Integration.Mvc.RegistrationExtensions.AsModelBinderForTypes( builder.RegisterType<CustomModelBinder>(), typeof(CustomModel));
But I have not found a way to register the ModelProvider with Autofac.
Is there a way to do it?