Factory Functions - Design Patterns in JavaScript

Опубликовано: 17 Октябрь 2024
на канале: TomDoesTech
6,944
225

Repository: https://github.com/TomDoesTech/js-des...

Factory functions are functions that create and return objects. A single factory can create different objects that share properties and methods.

0:00 Introduction
0:28 Object literals
0:58 Methods and the this keyword
2:45 Simple example
4:20 Realistic example

🌎 Follow me here:
Discord:   / discord  
Twitter:   / tomdoes_tech  
Facebook:   / tomdoestech​  
Instagram:   / tomdoestech​  
TikTok:   / tomdoes_tech  
☕ Buy me a coffee: https://www.buymeacoffee.com/tomn