20 ms·
I haven't found a use for a lot of these features, a lot of them just seem very ad-hoc additions to the language. A class based object oriented model would have
by cpleppert 14y ago
I haven't found a use for a lot of these features, a lot of them just seem very ad-hoc additions to the language. A class based object oriented model would have solved a lot of issues relating to the myriad ways to implement object orientation in javascript. The schizophrenic like approach we have right now isn't being helped by incremental changes driven by the lowest common denominator of what can be implemented in a web browser development cycle.
Knowing the [Good Parts](http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockford/dp/0596517742 http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...) helps but you just can't keep adding parts that you think may be good.
- thingification 14y agoHere is the context that makes these features not seem ad hoc: http://www.infoq.com/interviews/ecmascript-5-caja-retrofitting-security http://www.infoq.com/interviews/ecmascript-5-caja-retrofitti... Many of the additions (including object.freeze) and changes were made for the purpose of making JavaScript usable as an object capability language. Mark Miller explains the background and some of the changes in the video linked above.