4 ms·
> Avoid CoffeeScript. Most of its better features are now in ES6, a standard. This argument against CoffeeScript isn't very objective. One of CoffeeScript's be
by kenOfYugen 11y ago
> Avoid CoffeeScript. Most of its better features are now in ES6, a standard.
This argument against CoffeeScript isn't very objective.
One of CoffeeScript's best features is the minimalistic and expressive syntax.
"CoffeeScript (#6) appears dramatically more expressive than JavaScript (#51), in fact among the best of all languages."[1]
"CoffeeScript is #1 for consistency, with an IQR spread of only 23 LOC/commit compared to even #4 Clojure at 51 LOC/commit. By the time we’ve gotten to #8 Groovy, we’ve dropped to an IQR of 68 LOC/commit. In other words, CoffeeScript is incredibly consistent across domains and developers in its expressiveness."[1]
Using the author's train of thought I could state:
"Avoid Bluebird[2]. Most of its better features are now in ES6 promises, a standard."
Yes promises are in the ES6 standard, but that's not the best feature of bluebird. There were and are many promise based libraries, but bluebird was built for unmatched performance. One will use it if performance matters.
Even today it's faster than the native implementations of promises [3].
> Tooling (such as CoffeeLint) is very weak.
Maybe because, as it turns out, in CoffeeScript you don't need a lot of tooling. Why would that be a bad thing?
> Electron is the foundation of the great Atom editor and can be used to make your own applications.
Atom is written in CoffeeScript [4].
[1] http://redmonk.com/dberkholz/2013/03/25/programming-languages-ranked-by-expressiveness/ http://redmonk.com/dberkholz/2013/03/25/programming-language...
[2] https://github.com/petkaantonov/bluebird https://github.com/petkaantonov/bluebird
[3] http://programmers.stackexchange.com/questions/278778/why-are-native-es6-promises-slower-and-more-memory-intensive-than-bluebird http://programmers.stackexchange.com/questions/278778/why-ar...
[4] https://github.com/atom/atom https://github.com/atom/atom
- k__ 11y agoI'm using LiveScript for private stuff and ES6/JSX in production. LS is a pleasure to write. But the tooling on ES6 is nicer I must admit :/
- kenOfYugen 11y agoOut of curiosity, what tools are you referring to that are nicer on ES6 and not applicable to LS? Could you give examples?
- k__ 11y agoall the auto-complete stuff in atom.
- RobertKerans 11y agoI think the key point he makes (even though it's almost throwaway at the end of the paragraph) is that the community is rapidly declining. I agree with you completely on the syntax: it's not my bag (I prefer writing plain [ES6] JS), but idiomatic CoffeeScript is remarkably expressive. But the decline, which is undoubtedly accelerating, is problematic. I'm busy ripping CS code out of several big Rails apps simply for the sake of maintainability going forward. Good CoffeeScript code is not quite 1-to-1 translatable to/from JS; it's a simple language, but it is an actual language with its own constructs. I feel it's important to make it as easy as possible for others to maintain code I've written, and using JavaScript makes that easier than having it written in another language. The Bluebird comparison I think is off for that reason - Bluebird is a JS library: you only need to know the API, it's still JS. If a developer understands promises, there's no great step between native and Bluebird. (I totally agree with what you're getting at btw, I just think [maybe for the worse, maybe not] that it is pragmatically better, with the advent of ES6, to stick to JS; TypeScript maybe gets a let-off here as it's just a thin layer on top, not a different language).