Playground for studying design patterns, solid principles, GoF, testing and more with TypeScript
This repo has been created to study design patterns, solid principles, GoF, testing and more with TypeScript.
All topics are in the src
folder, separated by they topic. All topic has an README.md
file and his sub topics as well.
To install follow these steps:
Clone the repo
git clone [email protected]:deverebor/typescript-design-patterns-study.git
Enter the repo directory
cd typescript-design-patterns-study
Install the dependencies
npm i
Follow these steps:
- npm run start:srp - single responsibility principle
- npm run start:ocp - open closed principle
- npm run start:lsp - liskov substitution principle
- npm run start:isp - interface segregation principle
- npm run start:dip - dependency inversion principle
- npm run start:legacy
- npm run test - test the project
- npm run test:silent - silent with watch test
- npm run test:coverage - to generate coverage report
- creational
- Singleton - npm run creational:singleton
- Builder - npm run creational:builder
- ProtoType
- npm run creational:proto-deep - Deep Clone
- npm run creational:proto-shallow - Shallow Clone
- npm run creational:proto-js-obj - JS Object Clone
- npm run creational:proto-js-func - JS Function Clone
- FactoryMethod - npm run creational:factory
- AbstractFactory - npm run creational:abstract-factory
- structural
- Composite
- npm run structural:composite-classic - Classic Structure
- npm run structural:composite-validation - Validation Structure
- Adapter - npm run structural:adapter
- Bridge - npm run structural:bridge
- Decorator - npm run structural:decorator
- Facade - npm run structural:facade
- Proxy - npm run structural:proxy
- Flyweight - npm run structural:flyweight
- Composite
- behavioral
Initialize the project you want
npm run start:dip
Developer with ❤️🔥 by Lucas Souza (@deverebor)