Hacker News new | past | comments | ask | show | jobs | submit login

Its the javascript community as a whole that is divided, generally between imperative/OOP and functional devs. Has nothing to do with Node or otherwise.

Even if you like classical inheritance, the Class keyword is poorly implemented for it, from both a normal OOP language's point of view OR from a prototypal inheritance point of view. It's bad at both.




Classes are fine if you understand they're just syntactic sugar for the already extremely widespread constructor+prototype pattern.

The primary reason a significant part of the community hates the ES6 classes is that the class keyword is misleading for people who don't understand prototypal inheritance.

The OOP vs FP divide is orthogonal to that as the FP devs in question generally disagree with the constructor+prototype pattern to begin with (and often shun prototypal inheritance entirely).

There's also the people who want JS to be more like Haskell/Lisp, but they've mostly moved to LiveScript and ClojureScript and only occasionally complain from the sidelines.


> There's also the people who want JS to be more like Haskell/Lisp, but they've mostly moved to LiveScript and ClojureScript

You forgot about Purescript:

http://purescript.org/


What exactly is bad about ES6's `class` from a classical inheritance point of view?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: