Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What are good JavaScript OOP resources? [closed]

People also ask

Is JavaScript good for OOP?

JavaScript is a very good language to write object oriented web apps. It can support OOP because supports inheritance through prototyping also properties and methods. You can have polymorphism, encapsulation and many sub-classing paradigms.

Which oops concept supported by JavaScript?

JavaScript lets objects inherit properties from parent objects or any other objects. It uses the concept of prototypal inheritance.

Is Oops outdated?

OOP is not outdated.

Why use OOP in JavaScript?

OOP has everything to do with encapsulation and object composition pattern. So long that you are putting objects in objects, you are doing OOP. Just like Functional programming is all about putting functions in functions (function composition).


You can see great code examples of Javascript in mainstream libraries like jQuery. I've learned a lot just reading it's source code. There's nothing better than reading sources that are working in millions of websites and are concerned about best practices.


In the same vein as The Good Parts, Douglas Crockford's website has many good articles on JavaScript and OOP, such as Prototypal Inheritance, Classical Inheritance in JavaScript, etc.


In addition to the previous references to Crockford's work, I recommend you read this perspective on the contrast of Functional vs. Classical inheritance patterns in JS:

Inheritance Patterns in JavaScript by Michael Bolin


The recent Crockford on JavaScript video talks are worth watching - Act III: Function the Ultimate covers OOP in JavaScript.