Decorator Pattern in TypeScript
The decorator pattern is a structural pattern, that allows you to attach additional responsibilities to an object at runtime.
The decorator pattern is used in both the Object Oriented and Functional paradigms.
The decorator pattern adds extensibility without modifying the original object.
The decorator forwards requests to the enclosed object and can perform extra actions.
You can nest decorators recursively.
- Component Interface…