I'm sold. Does it have a translator for all my old js, like sass-convert? And can I set it to watch a directory for changes and recompile if I save a file, like "compass watch"?
As for watching a directory for changes, absolutely. Just pass "--watch" to the "coffee" executable. For example:
coffee --compile --watch --output lib src/
coffee -cw -o lib src/
Which will watch "src" for changes, and compile all ".coffee" files inside to ".js" files in "lib", preserving the directory structure. if x = y
The compiler should raise a syntax error.So, although '=' is available to make transitioning from other languages smoother, idiomatic CoffeeScript would use ':' for assignment, both within and outside of object literals, and would use 'is' for equality. Harder to make a bug out of:
if x is y