Why Object Oriented Programming ?OOP is one of the multiple approaches you can take to structure your code.
It doesn't fit any situation, it's proven to be an outstanding approach to handle large/complex applications.
It will help you keep your code clear, extensible, decoupled and maintainable.
For further information on OOP, just check some of the links on this article.
Extensions and Design PatternsjsClass accepts extensions, that is, custom modifications that you can attach to classes.
Some are tightly related to Design Patterns.
These are general reusable solutions to commonly occurring problems.
Each extension is very well documented on the code, specifying the different ways yo use them. Also, check the demo to see each in action.
This is the list of built-in extensions:
abstractCreate abstract classes that cannot be instantiated without extending.
extendUse inheritance, make child classes extend base classes.
getsetGenerate getters and setters for private members of your class.
implementCreate Interfaces that define methods that need to be defined, in order to implement them.
membersAdd members to the instances of your class. It's a shortcut for SomeClass.members(...).
moduleSave your class into a Module. If required, all the namespace is created before saving the class.
propertiesGenerate properties to control the access to private members of your class.
singletonCreate Singleton classes that can only be instantiated once.
staticsAdd static methods or data to your class. It's a shortcut for SomeClass.statics(...).