5168 shaares
38 private links
38 private links
The main principle with Object Oriented Programming (OOP) is the use of Classes (Functions in JavaScript) to create objects, and that objects are implemented in a manner that allows them to adopt Inheritance, Polymorphism, and Encapsulation. We are only concerned with Inheritance and Encapsulation, since only these are applicable for OOP in JavaScript. Essentially, objects can encapsulate functionalities and inherit methods and properties.