Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

thank the lord, i can't imagine something as ubiquitous as javascript still has no syntactically intuitive class system


Why not? Classes are just one implementation/realization of OOP. They're the most common, to be sure, but they're by no means the only way to do objects, nor are they necessarily the best.

“There is more to OOP, Horatio, than is dreamt of in your philosophy.”


The MooTools library implements declarative class syntax for regular javascript:

http://mootools.net/docs/core/Class/Class


The next trick is for libraries to make sure their homegrown class systems are migrated to ES6 classes, or interop with consistent semantics.


MooTools has always aimed to be compliant with the next version of Ecma. In a lot of ways it is a shim for whatever is next.




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

Search: