Implementing the Strategy Pattern in NestJS

Implementing the Strategy Pattern in NestJS

Writing Clean, Decoupled Code with the Strategy Pattern One of the biggest signs of a mature backend developer is understanding how to decouple high-level business logic from low-level implementation details. That’s exactly what the Dependency Inversion Principle...
NestJS Hexagonal Architecture + CQRS | Full Project

NestJS Hexagonal Architecture + CQRS | Full Project

In this lecture, we’ll build a complete NestJS project using Hexagonal Architecture and CQRS from the ground up. You’ll learn how to structure your code around core domain logic, application services, and infrastructure adapters — creating a clean, maintainable, and...
NestJS Custom Decorators

NestJS Custom Decorators

Decorators are a design pattern that can help us to write cleaner code that adheres to the Single Responsibility Principe and Open-closed Principle. In object-oriented programming, the decorator pattern is a design pattern that allows behavior to be added to an...
NestJS Domain Driven Design With Class Transformer

NestJS Domain Driven Design With Class Transformer

This article will show how we can utilize the powerful class-transformer library to implement clean domain-driven code in a NestJS application. By the end, you will have a pattern to implement NestJS domain-driven design. Class Transformer Its ES6 and Typescript era....
NestJS Factory Method Pattern

NestJS Factory Method Pattern

In this article, I want to show you how to implement the factory method pattern in NestJS to allow for cleaner code. By the end of this article, you should be familiar with the factory method pattern & how it can be used in a NestJS application. Factory Method...