DEV Community

Discussion on: Stop using if else

 
andreidascalu profile image
Andrei Dascalu

As long as you also define methods on the prototype, yes. Object oriented isn't just "call stuff objects". The core of OOP is the communication between objects, regardless of how they are implemented. Encapsulation, inheritance/composition, etc. JS very much an OOP language, but if it's not an instantiated structure according to the definition, it's not an OOP object.

Some comments have been hidden by the post's author - find out more