top | item 16755863

(no title)

mikegerwitz | 8 years ago

Those interested in how prototypes and classical inheritance relate (and don't) may be interested in work I did on GNU ease.js, which works with ECMAScript 3+. I have since extended it to support Scala-like traits.

https://www.gnu.org/software/easejs/manual/easejs.html#Imple...

I also wrote a paper on some of the concepts:

https://mikegerwitz.com/papers/coope/coope.pdf

The `class' keyword in JS still leaves much to be desired; it's just syntatic sugar around the prototype model. There's nothing wrong with that model---it's just important to understand how it differs from what OOP developers traditionally expect.

discuss

order

nostalgeek|8 years ago

> it's just syntatic sugar around the prototype model.

No it allows "super" late binding, something you cannot do with functions and prototypes. It's not just "sugar".