Creational patterns abstract the instantiation process. They become more important as systems depend more on composition rather than class inheritance. They are used to simplify the creation of objects to make them more adaptable to different situations.
There are a few types of creational patterns:
- Abstract Factory
- Singleton
- Builder
- Prototype
- Factory method
const dog = new Dog();
console.log(dog.bark()) // woof