Introduction In Domain-Driven Design (DDD), repositories play a crucial role—they represent a boundary between the domain model and the underlying infrastructure. But in event-sourced systems, developers often fall into one of two traps: either overs...
Developing great contracts is one of the most crucial parts of software engineering. The components exported from your design system are no exception. In a React application, this means designing thoughtful and opinionated component APIs. Yet, there’...
In the past few years, there’s been a growing trend of criticizing TypeScript’s enum feature. Videos, blog posts, and tweets call for avoiding them entirely, and many developers are now defaulting to union types or const objects instead. And yes—Type...
In the world of Domain-Driven Design (DDD), certain principles often feel like ironclad rules—one of which is that every aggregate must have a unique identity. But what if I told you that sharing IDs across aggregates isn’t inherently wrong and, in f...
I still remember the very first time when the DRY principle was preached to me. "Whenever you find yourself writing duplicate code, always remember DRY. Don't Repeat Yourself" they said. I can only imagine that the majority of us has received this in...
Introduction Based on how an application has been put together, it is entirely possible for a developer to find themself in an unfortunate position where creating isolated unit tests is not frequently possible. As a result, they would resort to more ...