Toptal
Handling all validation in domain objects results in objects that are huge and complex to work with. In domain-driven design, using decoupled validator components allows your code to be much more reusable and enables validation rules to rapidly grow.
In this article, Toptal engineer Josip Medic shows us how validation can be decoupled from domain objects, made context-specific, and structured well to achieve more sustainable validation code.
Source: Toptal
Toptal
Handling all validation in domain objects results in objects that are huge and complex to work with. In domain-driven design, using decoupled validator components allows your code to be much more reusable and enables validation rules to rapidly grow.
In this article, Toptal engineer Josip Medic shows us how validation can be decoupled from domain objects, made context-specific, and structured well to achieve more sustainable validation code.
Source: Toptal