MCPcopy Index your code
hub / github.com/Sean-Bradley/Design-Patterns-In-TypeScript

github.com/Sean-Bradley/Design-Patterns-In-TypeScript @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
787 symbols 1,224 edges 142 files 0 documented · 0%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Design Patterns In TypeScript

This repository focuses on the 23 famous GoF (Gang of Four) Design Patterns implemented in TypeScript.

It is supplementary to my book titled Design Patterns In TypeScript

   https://www.amazon.com/dp/B0948BCH24

   https://www.amazon.co.uk/dp/B0948BCH24

   https://www.amazon.in/dp/B094716FD6

   https://www.amazon.de/dp/B0948BCH24

   https://www.amazon.fr/dp/B0948BCH24

   https://www.amazon.es/dp/B0948BCH24

   https://www.amazon.it/dp/B0948BCH24

   https://www.amazon.co.jp/dp/B0948BCH24

   https://www.amazon.ca/dp/B0948BCH24

   https://www.amazon.com.au/dp/B094716FD6

(ASIN : B0948BCH24 / B094716FD6)

and courses on Udemy and YouTube (Channel membership required)

 

Course Access

There are 3 possible ways to access the video content in this course,

  1. Udemy : https://www.udemy.com/course/design-patterns-typescript/?referralCode=6384C079FB0A503DB9D9
  2. YouTube Membership : https://www.youtube.com/channel/UCmUILI2AWt2MSUgPlZwFdOg/join
  3. Paperback/Kindle : https://www.amazon.com/dp/B0948BCH24 : (ASIN : B0948BCH24 / B094716FD6)

TIP

Design Pattern In TypeScript (Paperback/Kindle) includes Video Access Codes to view videos for FREE from the official documentation website at https://sbcode.net/typescript/


TIP

Get Udemy Discount Coupons at https://sbcode.net/coupons


Setup Project

git clone https://github.com/Sean-Bradley/Design-Patterns-In-TypeScript.git
cd Design-Patterns-In-TypeScript
npm install -g typescript
npm install
tsc -p ./src

# run each pattern tutorial separately, e.g,
node ./dist/factory/factory-concept.js
node ./dist/factory/client.js

Overview

A Design Pattern is a description or template that can be repeatedly applied to a commonly recurring problem in software design.

A familiarity of Design Patterns will be very useful when planning, discussing, managing and documenting your applications from now on and into the future.

Also, throughout the book, as each design pattern is discussed and demonstrated using example code, I also introduce new TypeScript coding concepts with each new design pattern. So that as you progress through the book and try out the examples, you will also get experience and familiarity with some finer details of programming with TypeScript.

So, in the book, you will learn about these 23 Design Patterns,

Pattern Types

... Refer to Book or Design Patterns in TypeScript website to read textual content.

Class Scope and Object Scope Patterns

... Refer to Book or Design Patterns in TypeScript website to read textual content.

Extension points exported contracts — how you extend this code

IAbstraction (Interface)
(no doc) [17 implementers]
src/bridge/bridge-concept.ts
IMove (Interface)
(no doc) [7 implementers]
src/strategy/client.ts
IAbstractExpression (Interface)
(no doc) [12 implementers]
src/interpreter/interpreter-concept.ts
ISwitchCommand (Interface)
(no doc) [8 implementers]
src/command/iswitch-command.ts
IHandler (Interface)
(no doc) [7 implementers]
src/chain-of-responsibility/chain-of-responsibility-concept.ts
IExampleState (Interface)
(no doc) [12 implementers]
src/state/client.ts
IProteus (Interface)
(no doc) [6 implementers]
src/proxy/iproteus.ts
IAggregate (Interface)
(no doc) [16 implementers]
src/iterator/iterator-concept.ts

Core symbols most depended-on inside this repo

interpret
called by 17
src/interpreter/iabstract-expression.ts
request
called by 14
src/state/client.ts
execute
called by 11
src/command/icommand.ts
method
called by 10
src/bridge/bridge-concept.ts
logEvent
called by 9
src/facade/reports.ts
Add
called by 8
src/decorator/add.ts
attach
called by 7
src/composite/folder.ts
registerKill
called by 7
src/memento/game-character.ts

Shape

Method 368
Class 347
Interface 54
Function 17
Enum 1

Languages

TypeScript100%

Modules by API surface

src/observer/data-view.ts22 symbols
src/command/command-concept.ts19 symbols
src/bridge/bridge-concept.ts18 symbols
src/state/client.ts17 symbols
src/builder/builder-concept.ts17 symbols
src/visitor/client.ts16 symbols
src/observer/observer-concept.ts16 symbols
src/strategy/strategy-concept.ts15 symbols
src/strategy/client.ts15 symbols
src/state/state-concept.ts15 symbols
src/factory/factory-concept.ts15 symbols
src/composite/composite-concept.ts15 symbols

For agents

$ claude mcp add Design-Patterns-In-TypeScript \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact