Jun 12, 2023
Good one,
So there are 3 things, dto->data model-> domain model.
In my case I am just taking data model and domain model (ps: using data model as dto). So keeping mappers in domain layer-
" Ensures that the mapping process is closely tied to the domain models and keeps the conversion logic within the domain layer. It maintains a clear separation of concerns and allows for easy adaptation of the data layer without affecting the domain layer.".
It totally depends on your project structure, what you said is totally correct, if following CLEAN strictly and using all 3 models(dto,data,domai).
Pls add your thoughts.