4 ms·
CoffeeScript and co. ensure new developers who adopt those languages never actually be proficient in JavaScript. Its not a good thing. Perhaps its me, but I jus
by harel 14y ago
CoffeeScript and co. ensure new developers who adopt those languages never actually be proficient in JavaScript. Its not a good thing. Perhaps its me, but I just don't get why I'd want to write in one language in order to get code in another. Why not just learn the target language?
And please don't bring up the "You write C which gets compiled to assembly or Python which ends up as C" etc. Its not the same thing. JavaScript is not Assembly and its not Machine Language. Its a very simple language and its quirks can be learned quite easily. Its not that more verbose than CoffeeScript. Don't get me wrong, I think CoffeeScript's syntax is nice, but its nice in an academic kind of way, not in as a replacement for a language that if you work and develop for the browser, you should know very well and be friends with. Its a dangerous short cut.
- account_taken 14y agoOne cannot be proficient in CoffeeScript without being proficient in JavaScript. How could they debug anything?
- harel 14y agoFirst of all why would you want to end up debugging on one language and writing on another? This is why I specifically mentioned 'new developers'. But I also mean developers who know basic JavaScript and jump on the CoffeeScript hype wagon because its there and its hip.
- kam 14y agoSourceMap.
- hilko 14y agoExactly. I would never advise someone to use CoffeeScript without first knowing JavaScript, but I think very few people would do this anyways. And even if they tried, aside from debugging issues, I think the article shows that it's pretty hard to work with CoffeeScript if you don't understand the underlying output code.
- tlrobinson 14y ago"Perhaps its me, but I just don't get why I'd want to write in one language in order to get code in another. Why not just learn the target language?" I bet someone has uttered nearly these exact words when debating assembly versus C/Fortran/etc.
- harel 14y agoAs I predicted and mentioned in my original comment - That argument does not hold. Its not the same thing. Assembly is hard. There's no way to look at it and say its a straight forward easy language (without sacrificing 100% of your social life that is). You need to understand the hardware you're writing to. You need to be intimate with it. Be on first name basis with all the registers. JavaScript is a simple language with modern syntax. Its not assembly. Anyone who looks at JavaScript and things "Oh, Assembly" needs a change of careers or a new pair of spectacles. Yes it got quirks, like anything else, but you can learn them and write your own JavaScript.
- tlrobinson 14y agoJust because the syntax is "modern" doesn't mean it couldn't be better. Why should we give up now and be content with whatever we're stuck with?
- harel 14y agoIt can always be better. But you are investing in something that will write code for you for a browser platform that you should understand fully. Python and Ruby can also be better - perhaps we should write a language that compiles to Python or Ruby so we're not stuck with it? The 'better' solution was to allow more languages to interact with the dom and possibly that will happen in the future (Dart?). But to have an intermediary language that produces code for you which you cannot fully control, to run on a platform (the browser) which you at the moment have not much choice in the matter just to avoid punching a few keys or because you don't like the language, to me, doesn't sit well. To each his own I guess.
- nilkn 14y ago
- losvedir 14y agoI think you may be missing the point of coffeescript. > Perhaps its me, but I just don't get why I'd want to write in one language in order to get code in another. Why not just learn the target language? This seems to imply to me you think most coffeescripters don't know javascript? I've always thought coffeescript was for people who _did_ know javascript, and just wanted a little neater syntax. Why use it? For the same reason I tweak my text editor: when I spend hours a day doing something, even small efficiency wins add up. I agree that learning only coffeescript, and not javascript is a bad idea. edit: toned down language.
- Zelphyr 14y agoYou may be right that the people who write CoffeeScript already know JavaScript. But as the popularity of CoffeeScript increases so will increase the number of developers who only know CoffeeScript and little to no JavaScript. This may be a temporary problem, though, as it may also become increasingly unnecessary to know JavaScript. But it WILL be a problem. This isn't and won't be limited to CoffeeScript though. There are still a ton of "developers" out there who know jQuery or Dojo or, God forbid, Ext.js but actually know little JavaScript. A friend of mine was recently interviewing a guy who claimed to be a JavaScript developer but didn't know that "foo['bar']" was the same as "foo.bar". No doubt the guy could glue things together in some library blindfolded but the fact remains; he didn't know JavaScript and it cost him a job.
- harel 14y agoI agree, though I quite like Ext.js and 'god forbids' dojo...