DEV Community

Discussion on: Object Oriented Programming 💊

Collapse
 
efpage profile image
Eckehard

I think there are good reasons why classes have been introduced in ES6, so you can use both, a prototype based approach and a class based approach today.

Classes contain data and procedures (called methods), so, inside, a class features a procedural approach (in fact, we are using functions, but as the term "functional programming" is already occupied, the classical approach often is called "procedural"). Often, it is a very natural transistion from procedureal code to class based OO.