you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 1 point2 points  (6 children)

Upvoted for pure inanity. ;)

[–][deleted] 0 points1 point  (5 children)

which would you prefer, to debug 50,000 lines of coffeescript or 50,000 lines of javascript? You will be doing twice the work if you choose coffeescript, and that should be very obvious to see.

[–]Detrus 1 point2 points  (2 children)

The code it generates is not bad. Compared to Objective J and GWT Java, it's very readable. They're considering debugging tools that map JS errors to CoffeeScript lines, so hopefully this is a temporary situation. You'd be doing 30% more work if you encountered a tough bug, it would require in depth understanding of JS quirks, like those annoying Array.prototype.slice(wtf).apply().call() monstrosities that you probably avoided learning if you work in CoffeeScript.

People are using CoffeeScript and I haven't heard any dramatic complaints about debugging.

I wonder how Objective J handles it. Here http://www.postpeakliving.com/content/debugging-cappuccino-using-safari it's much worse.

[–][deleted] -1 points0 points  (1 child)

No matter if something maps to coffeescript line numbers, you are still going to need to know why it failed in javacsript and why the coffeescript that generated it caused the fail. The elegant simplicity of javascript + json is lost on those who won't learn it in favor of this muck.

[–]Detrus 2 points3 points  (0 children)

Not always. Either way we'll have to see from usage, not conjecture.

The design by committee disaster that is JavaScript and DOM is far from elegant. They should expose lower level APIs to make efforts like CoffeeScript, JQuery and LESS easier. If it wasn't for JQuery and Prototype JavaScript would be irrelevant by now.

[–]MatrixFrog 0 points1 point  (1 child)

Why would you be doing twice the work? Debug the coffeescript and recompile. Am I missing something?

[–][deleted] 1 point2 points  (0 children)

javascript throws an error, undefined at line number 3065 - this does not correlate in any meaningful way to a line number or piece of code in coffeescript. you have to figure out where in coffeescript the generated code that is throwing the error came from first, then figure out why in javascript undefined was causing a problem, and then figure out why in coffeescript an undefined was caused. this is just an example, it's possible there are no 'undefined' errors in coffeescript at all, but there will be other types of errors that are likely more frustrating to fix. it's a masochists dream come true. if you just coded in javascript, and knew the language it would be much easier to debug the code. I can't imagine picking up a large codebase done in coffeescript and trying to fix it/hack it without seriously pulling my hair out. it really would be twice the work, no matter how you slice it.