CoffeeScript: Accelerated JavaScript Development
pragprog.com
pragprog.com
I was planning to post this link later, when the book becomes available. I can't share any details yet, but look for an announcement next week. I run @coffeescript on Twitter, so you'll definitely stay updated if you follow me there.
Incidentally, you could add it to your wish list on Amazon: http://www.amazon.com/CoffeeScript-Accelerated-Development-T...
https://github.com/jashkenas/coffee-script/wiki/List-of-lang...
I'm wondering how they compare, and what people have to say.
For heavily async code, those other tools are well worth looking at.
Code-wise, I'm only a minor contributor to CoffeeScript. I wouldn't be the right person to write a book on how the CoffeeScript compiler works. (Thankfully, some of those people agreed to be technical reviewers for the book.) But I have been an active participant in the language's community from early on.
Criticisms welcome. We're aware of some technical issues (most notably, there's no syntax highlighting for the CoffeeScript snippets), which will be fixed shortly.
I think that will be fun since Lua's syntax is ... not so sweet i think.
Plus, learning CoffeeScript wouldn't be much use if the docs for every JS library read as gobbledygook, right?
All I'm getting at is that I'd like to see CS eventually become a language in its own right rather than an extra tool for JS developers. I think this is completely feasible if we start treating it that way and create the tools and documentation to that end. I think it is a serious improvement over JS and could eventually replace JS for the common programmer.
By the way, thanks for all your work, I'll definitely be picking up the book.
Yeah, totes. Brendan Eich himself has assured me that the Mozilla folks are dedicated to adding debug support for CoffeeScript (and other compiled JS languages) to Firefox. So the underlying JS will be less and less of a concern as the tools get better.
At the same time, though, that'll probably lead to languages that go further than CoffeeScript taking hold, just as Clojure is rockin' it on the JVM despite being really far removed from Java. I like CoffeeScript a lot, but when JavaScript really does become bytecode, people will want to code in something less JavaScript-like. (Or CoffeeScript may become the new C... "assembly with syntax," in pg's words.)
Java and Scala.
Erb and Haml.
CSS and Less/Sass.
Edit: Walking and driving.
I just started using CoffeeScript for a project of mine and while it did clean up the messy look of the Javascript, it doesn't improve much upon Javascript feature-wise. I felt like I was still writing Javascript, it just looked a little better.
This is the only comparison on your list that is remotely appropriate. In no meaningful way is it true that
CoffeeScript:Javascript :: C:Assembler
Javascript is not a low-level language resembling a primitive machine interface, and CoffeeScript mostly provides syntactic sugar, not new semantics or a different paradigm.In order for A:B :: C:D it is not the case that A and C need to be similar, nor B and D.
The comparisons made in the GP have very little in common. The Java:Scala distinction is not similar to that of ASM:C, and neither has a similar relationship to that of HAML:Erb. So there are many objections that can be made to the analogy, especially that the analogous relationships provided are not even analogous to each other!
The sentence you quoted makes some assumptions of the reader's knowledge, namely that the reader understands "syntactic sugar" to be a process of trivial, linear transformation. The basis of the objection is not that Javascript is unlike ASM; the objection is that the relationship between Javascript and CoffeeScript is between a high-level scripting language and a trivial transformation layer of that language.
On the other hand, ASM is a low-level interface and C is a paradigmatic shift (comparatively) in programming that introduces semantics which are divorced (to an extent) from their machine implementations.
That relationship is not analogous to Javascript:CoffeeScript, as it is not nearly as significant.