Using AngularJs Decorators offers a convenient method to enhance functions in services without altering the original service. How can a similar approach be implemented with javascript classes?
In my current project, I have two libraries - one containing general logic and UI components, and the other focusing on specific features for the page being developed. The challenge is to inherit from the class defined in the core logic library and then utilize the extended functions from the main library. While this may appear to be a flawed design, the same functionality could be achieved using decorators in AngularJS. However, since I am utilizing plain ES6 Classes, what would be the best approach to accomplish this task?