🍕 Template Method pattern: Refactor and make your application plug-in-able

Опубликовано: 18 Апрель 2026
на канале: Saeed Esmaeelinejad
830
29

Template Method is one of the behavioral patterns which means you can manage the code to behave differently based on our logic. It is used to define a skeleton of an algorithm in a base class and other subset classes can follow the steps or even customize them. In this video, I'm going to refactor a code and use the Template Method pattern.

Check the code [TemplateMethod]: https://github.com/sa-es-ir/youtube-s...

#dotnet #aspnetcore #designpatterns #templatemethodpattern

Moments

00:00 - Intro
00:55 - Codebase before refactoring
02:42 - Refactor the code to use the Template Method
10:43 - Using Dependency Injection
14:36 - Run new code with Template Method

-------------------------------------------------------
Follow me on LinkedIn:
  / sa-es-ir