If you understand programming (there is a difference between knowing how to program and understanding, a lot of people lack the latter) there is absolutely no difficulty learning CS if you know JS.<p>I've been coding CS for over a year now and I like it, I've never found it hard to debug and it's just easier to read.
Did they? I can't get to the end of the thread 'cause their infinite scroll thing is not working on mobile safari. Looks like they should focus on coding instead.
I find this a curious debate to have so early in Discourse's life. There doesn't appear to be a pain point, so it's mostly speculation. If this happens, then that consequence, but if this happens, then that other consequence...<p>I would stick with CoffeeScript until it becomes painful. There is relatively little downside risk. If and when you have great people refusing to contribute code because they hate CoffeeScript, well, that'll be a pain point. On the other hand, what if you get a bunch of other people who like contributing code because they can do it in CoffeeScript?<p>Are there meaningful statistics collected? Until there are, or at least a weighty collection of anecdotes, I'm sure there's something more important to worry about.
Am I the only one that has trouble parsing this CoffeeScript? I thought the syntax was suppose to be cleaner than plain javascript:<p>MyApp.president = Ember.Object.create
fullName: (->
@get('firstName') + ' ' + @get('lastName')
).property('firstName', 'lastName')<p>How the hell am I suppose to read that?
If I've understood correctly, the most compelling argument (or at least the most seemingly objective one) is that CoffeeScript conflicts with planned features of ES6+, meaning that there is a risk that large CoffeeScript projects will be locked into the ES5 feature set.<p>Since Discourse is planning on being around long after ES6 becomes widely available, it was a winning argument.<p><a href="http://meta.discourse.org/t/is-it-better-for-discourse-to-use-javascript-or-coffeescript/3153/19" rel="nofollow">http://meta.discourse.org/t/is-it-better-for-discourse-to-us...</a><p>Also, one of the big reasons the Discourse devs liked CoffeeScript is because it makes it hard to commit common JS errors. Building JSHint into their workflow can help bring this protection back.
> CoffeeScript has significant whitespace. So instant no. It makes it a pain in the butt to parse. It's annoying. Most people (except for Python developers) don't like it. Due to being difficult to parse, you will have problems when you try to refactor. Not to mention the problems of re-indenting everything when you have really long and ugly blocks you want to clean up (happens).<p>maybe people should stop writing unindented ugly blocks in their non-indent-significant language then?
Is it just me or is anyone else finding it weird viewing a thread on Discourse from HN? It's basically the same thing IMO (although obviously this is a Discourse site announcement). I just hope this doesn't become a "thing" as it's just essentially same as linking to a forum post.
History repeats itself. This topic reminds me of QWERTY vs. Dvorak. People continue using something because everyone else is and they always have; not because it's the optimal option.
I supported the switch to JavaScript, despite being an avid Coffeescript developer. Why? Because any CoffeeScript developer worth their salt already knows JavaScript, and can translate the JS to CS and back quite simply (admittedly, it's not as nice as hand-written CS, and the compilation loses comments, but I still prefer it to writing the JS by hand if I'm doing a bunch). But many, many JS developers don't know CS, or don't like it.<p>Now, this only affects the first official client. I imagine that there will be a CS port of the JS client as soon as the switch is made. That's the great thing about using a client to a REST API - you can have several different front-ends. If this was to be the only client, I'm not sure if I would support using JS over CS.<p>(btw, I'm @benaiah on meta.discourse.org - I'm in the referenced thread)
I think the advantage of this project being open source becomes really clear in situations like this: I'd imagine js2coffee[1] will cover most of their bases, but in the situation that it <i>doesn't</i>, they have a (pretty active) Github community to fall back on for the finicky bits of conversion.<p>[1]: <a href="http://js2coffee.org/" rel="nofollow">http://js2coffee.org/</a>
I would discuss how I feel about coffeescript and interstitial white space sensitivity and the ilk, but I'll point to a blog post which expresses most of my views neatly: <a href="http://blog.izs.me/post/10213512387/javascript-is-not-web-assembly" rel="nofollow">http://blog.izs.me/post/10213512387/javascript-is-not-web-as...</a>
I developped a little layout library ( work in progress ) which is a port of a flash lib. and frankly coffeescript made it really easy and made me wrote far less code that pure javascript.<p>One can write readable code with Coffeescript , i use parenthesis in big scripts because it is more readable , and i dont use classes where not appropriate.<p>CS helped me write better javascript without the badparts so i dont need to be a human compilator and fix javascript each time i write it. I should not have to.<p><a href="http://mparaiso.github.com/Coordinates.js/" rel="nofollow">http://mparaiso.github.com/Coordinates.js/</a><p>It is not for everyone , but significant white spaces are not a problem if one is used to indent his code properly. I tried typescript too , which is good, but i found coffeescript more expressive. The truth is , i enjoy writing CS , i dont writing JS.