5 ms·
As a corollary I'd like to say: stop pushing JavaScript forward. There seems to be a lot of focus on providing syntactic sugar for things that already exist (li
by skwosh 11y ago
As a corollary I'd like to say: stop pushing JavaScript forward. There seems to be a lot of focus on providing syntactic sugar for things that already exist (like classes, decorators, etc) at the expense of flexibility and composability (executable class bodies, @foo vs normal function application, etc).
What JavaScript needs much more IMO is a (better) stdlib, with more datatypes and procedures than currently available (including big numbers, the various flavours of trees, better support for equality and comparison, etc).
- bhousel 11y ago>What JavaScript needs much more IMO is a (better) stdlib, with more datatypes and procedures than currently available (including big numbers, the various flavours of trees, etc). Isn't that "pushing JavaScript forward?"
- adrusi 11y agoMaybe what skwosh means is a moratorium on new features in javascript so that we can refocus on the features that are useful, and actually improve rather than complect the language.
- skwosh 11y agoThanks, that's what I mean. My feeling is that some of the syntactic extensions to the language are piecemeal and don't reflect the full expressivity of JavaScript.
- angersock 11y agoIt's slightly different. The addition of sets and symbols, for example, did little to change what an existing codebase looked like. Similarly, adding explicit trees, binums, and so on won't really change much. The improvements going on right now, though, seem mainly concerned with syntactical sugar and extra syntax. The problem (and I'm in a minority here, I think) is that this creep and bloat takes a quirky language that fits into one's head and instead starts making it a rat's nest of special-cases and odd interactions. This is the sort of thing that caused C++ so much trouble. Once they add annotations and shared state and threading (and that's coming), the party will be over and the earth salted.
- apalmer 11y agoAgreed. However I think to build on his argument, we should push JavaScript forward in a targeted fashion, based on its intended purpose. Level 1: There are known huge missing chunks of JavaScript that should be resolved as they severely limit the power of javascript as a development platform which lives in a network application. For instance modules, promises, etc... Level 2: There are known huge missing functionality which are missing which are well known elements of a sane UI framework which should be implemented because bottom line javascript is a UI scripting language. For instance properties and some kind of observable mechanism. Level 3: IS all the highly subjective and often syntatic sugar intended to make javascript work more like other programming languages like C# or Python. For instance classes,. arrow functions, generators, let statements... Generally the problem is the focus seems to be completely skipping Level 2, to get to Level 3.
- thekingofspain 11y agoThose phases exactly mirror the phases listed in the article.
- apalmer 11y agowhere in the article?
- thekingofspain 11y agohttp://www.quirksmode.org/blog/archives/2015/07/stop_pushing_th.html#link3 http://www.quirksmode.org/blog/archives/2015/07/stop_pushing...
- wging 11y agoThis is being done! Level 3 is being done, but level 2 is not being skipped. Modules: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/import https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe... Promises: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe... Data structures: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe... Obervable mechanism: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/observe https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
- pavel_lishin 11y agoJavascript has decorators?
- mkozlows 11y agoHigher-order functions do the same thing.
- bluefinity 11y agoYes, at least in ES7. Babel supports them.
- Roboprog 11y agoGood call. Basic numeric and date/time types need work. I don't really need "Java-fication" syntactic misfeatures.