Earlier quoted context omitted.
Maybe this sounds nitpicky but I'm just not a fan of languages that use indentation to denote block structure. It turns trivial code manipulations into tedious line-by-line exercises. I don't like it in Python or Haskell either. Other than that I see a lot to like in CS though.
For some reason Python's indentation really bugs me, but I am totally ok with it in haml, sass, and yaml.
Poll: Have you moved from JavaScript to CoffeeScript?
101–110 of 178 posts
Re: Poll: Have you moved from JavaScript to CoffeeScript?
#102After reading posts about it on here for maybe a year, I recently decided to try it for a small jQuery plugin. I enjoyed it so much that we immediately switched to writing all new code in CoffeeScript and have begun converting existing code as time allows. The benefits over straight JavaScript are amazing—I’d been writing careful code that drew from the ‘good parts’ mentality and pre-declared all variables, etc. Now…
Is it difficult to debug the resulting code?
Most of the problems we’ve dealt with have been due to using new syntax, figuring out when we need parentheses/how to pass anonymous functions, and so on.
Referring to the compiled output definitely helps, but we’re pretty familiar with JS at this point. Not sure how difficult it would be for those with less experience.
Re: Poll: Have you moved from JavaScript to CoffeeScript?
#103Re: Poll: Have you moved from JavaScript to CoffeeScript?
#104Re: Poll: Have you moved from JavaScript to CoffeeScript?
#105I don't like the Windows experience of CoffeScript. That's what's holding me back. I think I would use it if it had better Windows support. As far as I know CoffeScript requires node.js, npm and cygwin. Am I wrong?
If you're using CoffeeScript without Node, you're missing out. Fortunately, Cygwin-free Windows support is on the roadmap for Node 0.6.
Re: Poll: Have you moved from JavaScript to CoffeeScript?
#106I have used Javascript exclusively on client and server since late 2008. First Rhino and then Node. Before that I used Rails. I can understand the syntax gripes that some people have towards Javascript but I think this has more to do with a Ruby notion of "elegance" coupled with a lack of familiarity with Javascript then it does with actual issues with Javascript. In fact, I prefer Javascript to Ruby. I have gone the…
You may have been misinformed -- the values of direct, raw, fast code are a big part of the reason why CoffeeScript works the way it does, and why many scripts can end up running faster after getting ported to CoffeeScript. The golden rule of CoffeeScript is to avoid adding any library code to the runtime, and to avoid introducing any special calls, to the greatest extent possible. Many folks rely on a "forEach" (or…
for (var i = 0, ii = list.length; i
Or: for (var i = 0, ii = list.length; i
There are ways to make normal JavaScript not look ugly ;)EDIT: fixed minor oversight
Re: Poll: Have you moved from JavaScript to CoffeeScript?
#107Re: Poll: Have you moved from JavaScript to CoffeeScript?
#108It's heartening to see so many people responding to this poll. I hopped on the CoffeeScript bandwagon more than a year ago; a week of using it was enough to convince me to stop writing pure JS. It's become my favorite language, even overtaking Ruby. (Cue dhh at last month's RailsConf keynote: "Looking at CoffeeScript was the first time I got language envy.")
These last six months have been amazing: In December, CoffeeScript hit 1.0. In April, it officially became a part of Rails. In May, Jeremy Ashkenas gave a talk alongside Brendan Eich at JSConf. That same month, the beta of my book was PragProg's #1 direct seller.
So who knows what the next year holds for CoffeeScript? It's probably never going to take off in cubicle-land—and for that we should be grateful. But I would like to see it get more traction beyond the Ruby and Node.js worlds. (Pythonistas, represent!) And I'm sure we'll see far more high-profile projects written in it... and not just at 37signals.
For web developers, JavaScript is where the action is right now. And CoffeeScript is, in my opinion, the best way to write JavaScript.
Re: Poll: Have you moved from JavaScript to CoffeeScript?
#109This is going to be a very interesting poll result. Even 5 or 10% penetration is something remarkable, for a language as widely-used as JavaScript. If you feel like providing any more color beyond your vote, your impressions after using CoffeeScript in anger -- I'd love to hear 'em.
* packaging, how do I import modules or packages? Do these even exist?
* debugging, how do I do this?
* unit testing?
I installed CoffeeScript via node, then npm (node package manager) and am using it via the command line.
Something like the ipython (http://ipython.scipy.org/moin/) shell along with pdb (http://muffinresearch.co.uk/archives/2008/04/27/python-debug...) would help immensely in my adoption of CoffeeScript.
In a perfect world the repl/debugger would be built into the webapp and open a websocket to another webapp so I could introspect/debug the page from another page while it was running (turtles all the way down). This is similar to the workflow for developing server side software (Jython, Python, Java).