News for hackers. Stuff that matters.
Re:Why Do All the Great Node.js Developers Hate CoffeeScript? by mratzloff on Friday November 30, 2012 @05:24PM (#4855814)
#4 pretty much the only advantage of CoffeeScript is saving a few keystrokes, not worth spending time on

Well, I suppose you could also say that the reason I might use Ruby over Java is to "save a few keystrokes". I'm exaggerating to make the point that shortcuts for common tasks are important.

- String interpolation (`"foo#{bar}baz"`)

- Existence unary operator (`foo?`, `foo ? "bar"`)

- Splats (`(foo, bar...) ->`)

- Comparison chaining (`10 < foo < 20`)

- Loops and comprehensions (`x() for x in ["foo", "bar"]`)

- Destructuring (`[foo, bar] = items`)

- Ranges (`num for num in [1..10]`)

- Array slicing (`items[3..5]`)

- Object properties (`for own key, value of object`)

I think these are all substantive improvements to JavaScript, not even taking into account readability-improving sugar like post-conditions.

There are no comments on this comment yet.