-
Book Overview & Buying
-
Table Of Contents
TypeScript 5 Design Patterns and Best Practices - Second Edition
By :
This chapter demonstrated all the fundamental aspects of structural design patterns and how to utilize them effectively in practice. These patterns focus on the internal and external composition of classes and how they share implementations.
We started by discovering the details of the Adapter pattern and how it helps make classes work with others by implementing a common interface. Then, we explored the Bridge pattern, which allows us to separate and abstract from its implementation. We also learned that after using the Decorator and Proxy patterns, you can enhance the functionality of objects at runtime without using inheritance.
Then, we explored how the Façade pattern uses a simpler interface to control complex workflows. By structuring a group of objects as composites, you can create a hierarchical system that shares a common interface. Lastly, using the Flyweight pattern, you learned how to use a shared state to minimize memory usage or space.
Using these...