DEV Community

Discussion on: How to Integrate AutoFac 5 and AutoMapper 10 on your MVC 5 Project using Visual Studio 2019

Collapse
 
willydavidjr profile image
Willy David Jr

Hi @zorgoz ,

You need to declare _mapper field whenever you instantiate your Controller class. This is the initial code:

Alt Text

You can also see the complete code here: github.com/willydavidjr/AutoFacAnd...

Collapse
 
zorgoz profile image
zorgoz

Of course, if you have some IoC experience, you can figure this out. However, in my opinion, this article is targeting a less experienced audience. This is why I missed this part.

Thread Thread
 
willydavidjr profile image
Willy David Jr

Hi @zorgoz ,

I appreciate your feedback. I will update the article so that nothing will be missed out for future readers :)