Automapper in ASP NET Core using C# Dependency injection

preview_player
Показать описание

Configure Automapper in ASP.NET Core 3.1 or 5.0 application. Map complex object to another type by centralizing transform logic and remove duplicated code logic

Рекомендации по теме
Комментарии
Автор

your example is good, however, it doesn't show the very reason why AutMapper is fundamentally useful. In your Profile Class when creating the map, you practically mapped each and every single property of your Source to the Destination.... something which AutoMapper seeks to address. You should have let the Source.Address property be Mapped automatically to the Destination object.

DrWambua