4 ms·
I dislike using coffeescript mainly because the language is too flexible. Being able to optionally omit a ton of syntax has led to some annoying problems that
by agscala 14y ago
I dislike using coffeescript mainly because the language is too flexible. Being able to optionally omit a ton of syntax has led to some annoying problems that aren't obvious at first glance. This ambiguity is exacerbated by the way javascript is typically used (chained methods, nested lambdas, etc).
The other gripe I have is that debugging it is a pain in the ass since errors that come back reference the javascript code, not the coffeescript. Apparently this is a problem being worked on but it's still irritating.
- roh26it 14y agoBut because nesting is a pain-in-the-ass in coffeescript, I've become used to breaking down code into chunks and invoking functions which ultimately makes code more readable solving many other problems. I do agree on the debugging aspect. I always have to go back to the compiled javascript to understand errors. Can you please point me to solutions being worked upon in this regard? Open source?
- jrajav 14y agoOne of the things provided by the CoffeeScript Redux project is source mapping, which enables line-to-line correspondences for debugging. https://github.com/michaelficarra/CoffeeScriptRedux https://github.com/michaelficarra/CoffeeScriptRedux http://ryanflorence.com/2012/coffeescript-source-maps/ http://ryanflorence.com/2012/coffeescript-source-maps/
- roh26it 14y agoCoffeeScript Redux project seems interesting. Thanks!
- svachalek 14y agoI've found the second case is actually the fix to the first; any funky compiler interpretation of my source is immediately visible in the .js code. But overall I agree; I wish they'd fixed the JS quirks that they did, allowed indentation instead of braces, added their lambda syntax, and stopped about there. It goes too far on optional syntax and functional features that are gradually being added to JS anyway.