https://github.com/dancastillo/js-design-patterns
https://github.com/dancastillo/js-design-patterns
Last synced: 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/dancastillo/js-design-patterns
- Owner: dancastillo
- Created: 2021-08-12T01:24:40.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2021-08-12T01:25:04.000Z (almost 4 years ago)
- Last Synced: 2025-01-20T17:50:45.527Z (4 months ago)
- Language: JavaScript
- Size: 2.93 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Design Pattern
## Strategy Pattern
[Wikipedia Definition](https://en.wikipedia.org/wiki/Strategy_pattern) - a behavioral software design pattern that enables selecting an algorithm at runtime. Instead of implementing a single algorithm directly, code receives run-time instructions as to which in a family of algorithms to use[Example Code](./strategy/index.js)
#### Video Reference
* [Strategy Pattern - Christopher Okhravi](https://www.youtube.com/watch?v=v9ejT8FO-7I&list=PLrhzvIcii6GNjpARdnO4ueTUAVR9eMBpc&index=3)
* [Nothing is Something](https://www.youtube.com/watch?v=OMPfEXIlTVE)## Null Object Pattern
[Wikipedia Definition](https://en.wikipedia.org/wiki/Null_object_pattern) - an object with no referenced value or with defined neutral ("null") behavior. The null object design pattern describes the uses of such objects and their behavior (or lack thereof).[Example Code](./nullObject/index.js)
#### Video Reference
* [Null Object Pattern - Christopher Okhravi](https://www.youtube.com/watch?v=rQ7BzfRz7OY&list=PLrhzvIcii6GNjpARdnO4ueTUAVR9eMBpc&index=19)
* [Null Object Pattern - Web Dev Simplified](https://www.youtube.com/watch?v=D4Dja5WSZoA)## Observer Pattern
[Wikipedia Definition](https://en.wikipedia.org/wiki/Observer_pattern) - is a software design pattern in which an object, named the subject, maintains a list of its dependents, called observers, and notifies them automatically of any state changes, usually by calling one of their methods.[Example Code](./observer/index.js)
#### Video Reference
* [Observer Pattern - Christopher Okhravi](https://www.youtube.com/watch?v=_BpmfnqjgzQ&list=PLrhzvIcii6GNjpARdnO4ueTUAVR9eMBpc&index=3)
* [Javascript Observer Pattern - DevSage](https://www.youtube.com/watch?v=45TeJEmcqk8)