Re:A Case Against Using CoffeeScript
by ryanflorence on Tuesday December 13, 2011 @10:17PM
(#3350423)
That's a good point, and I've actually adjusted my color scheme to make fat and thin arrows different brightness, the fat brighter to call it out more.
For classes, I'm still unclear as to why you might even use the thin arrow, lest you're providing a mixin. Thoughts?
The constructor doesn't need one, and there is a small performance hit for binding =>.
Mixins... Can you show me an example?
Times when you need a reference to a canonical function object, like with $.proxy and $.unbind. (CoffeeScript could implement => to set the original function as a property of the bound function)
Added a question on github: https://github.com/jashkenas/coffee-script/issues/1934
To see what scope the fat arrow is bound to, all you need to do is scan up the parent scope in the file and look for a thin arrow (or a class declaration).
Your "whitespace problem" is my solution.