What is the best way to use Ninject with MVC 3 and how ?
It is using a controller factory ? or using NinjectHttpApplication ?
How to get ninject for MVC 3 ? Ive looked around but i can’t seem to figure out how to get the required ..mvc.dll
Any exemples would be helpful to me and others.
Thanks!
The best and simplest way to get Ninject for MVC 3 is adding the NuGet package Ninject.MVC3 using the NuGet Package Manager from within Visual Studio.
This will set up everything for you, add an
App_Startfolder to your application which containsNinjectMVC3.cs. At this point everything is already hooked up as Controller Factory thanks toWebActivator– you can just add your bindings inRegisterServices()or of course put them in a separate module.