1,926 karma · joined September 14, 2008
And, recently, Async JavaScript: http://leanpub.com/asyncjs
I'm available for freelance work on exceptionally interesting projects. I live in Cambridge, MA.
Website: http://trevorburnham.com/
Email: trevorburnham@gmail.com
[Edit: Updated link did work. Yeah, that license agreement is... not GPL-compatible. I'm guessing they duplicated the same boilerplate that they use for trial versions of their .NET libraries.]
To be fair, a lot of jQuery UI's development headaches come from supporting IE6, while Kendo only touts its support for IE7+...
However, I think the objections here would be moot if CoffeeScript's "list comprehensions" were called something else. They don't behave like list comprehensions in Python, but their behavior is perfectly consistent with the CoffeeScript philosophy that every expression has a value, and loops are expressions. That means that a single loop has a single list as its value, and a loop within a loop produces a list of lists. Note that unlike Python—or Harmony—there's no special delimiter to say "Give me a list comprehension." It's just the natural implication of how expressions in CoffeeScript work.
> OK im done ranting at invisible Brendan Eich now (as if hes going to read this) :-)
Write a more cogent piece, and he will. I'm amazed at how generous Brendan is with his time. He responds to tweets, and to numerous comments on his blog. When I asked him to look over the part of my CoffeeScript book that deals with the history of JavaScript, he not only did so, he also offered technical corrections and suggestions pertaining to other parts of the book. Just today, he took to HN to participate in a vigorous discussion of Google's forthcoming Dart language: http://news.ycombinator.com/item?id=2982256
In short: Rather than using the creator of JavaScript as a strawman in a meandering diatribe (one that's 3,700 words long and yet "only 1/3 done"), you should try to organize your thoughts and engage with him.
> In 1981, as Americans worried that Japan’s growing dominance in the auto business would be followed by a decline of the high-tech industry in the United States, Congress added another research and development credit, this time specifically for companies that increased their R.& D. spending from the previous year...
> Within a few years, the credit was being claimed by businesses with little technological background — fast-food restaurants, hair stylists and fashion designers. So Congress tried to restrict what research would qualify. The credit was denied for social science research and marketing...
> The failed attempts to restrict the R.& D. credit to basic research have been a boon for video game companies. Even when companies are merely creating new versions of existing games — conducting research that would have little value to anyone but themselves — their development processes usually involve enough experimental uncertainty to qualify for the tax break.
Not my experience. I love how short my code is. http://www.paulgraham.com/power.html
> there seems to be some interesting inconsistencies
Yeah, there are. These bug me less now than they did initially. Like any language, you have to know it well to use it well. But there's much less that you need to know about CoffeeScript than about, say, Ruby or Python. CoffeeScript's feature set is small enough that you can master it very quickly.
> is there a clear unambiguous grammar for it anywhere?
https://github.com/jashkenas/coffee-script/blob/master/src/g...
You and Alanis Morissette may call that ironic. I'd call it practical.
Um. Node.js gives you access to the filesystem... http://nodejs.org/docs/latest/api/fs.html
And anything you can do in Node, you can do from CoffeeScript code running under Node.
Of course, my sympathies go out to the Dev Days planners; this must have been a very hard decision for them, and an understandable one. Consider me RSVP'd for Dev Days 2012.
If I understand correctly, the idea is that you could set this up on a Rails project so that your team's copywriter would be able to edit your site's content directly on the page, rather than having to edit some ERB or Haml somewhere and refresh.
Note that because of the way the library works, you can only use the unicode equivalents on this fork—aliases like "ctrl" and "alt" will not work. (jQuery Hotkeys was written with a pretty hardcore approach to efficiency, so everything is 1:1. Keymaster uses an `indexOf` search each time a key is pressed, which has a negligible impact on performance in modern browsers.)
Sam Stephenson, the creator of Prototype.js, has been doing all kinds of awesome things with CoffeeScript and Node.js. And there's a chapter of my book on it...
(x, y) ->
for game_piece in @game_pieces
if game_piece.is_at x, y
@held_item = game_piece
@held_item.start_dragging x, y
break
compiles to function(x, y) {
var game_piece, _i, _len, _ref, _results;
_ref = this.game_pieces;
_results = [];
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
game_piece = _ref[_i];
if (game_piece.is_at(x, y)) {
this.held_item = game_piece;
this.held_item.start_dragging(x, y);
break;
}
}
return _results;
}
Notice that _results is initialized as an empty array... and is never modified, making it an utterly pointless return value. What's happening is that the CoffeeScript compiler has both implicit returns and list comprehensions, which means that it tries to return an array of all the values in the loop. All well and good, but the compiler doesn't try to do a list comprehension when there's a break... and yet it creates the frivolous _results variable anyway.Obviously I'm a fan of CoffeeScript; this is a minor bug and I expect it to be fixed. But let's be fair in making the case for it. Well-written JavaScript will always look better than CoffeeScript output; it just takes a lot more work.
dhh doesn't sound like he was ever a fan of Lighthouse: https://twitter.com/#!/dhh/status/63366853636009985
Incidentally, for those who are curious, the three patents used against Fototime (as well as more established companies like Flickr) can be found at http://www.google.com/patents?id=uiAPAAAAEBAJ, http://www.google.com/patents?id=0J8DAAAAEBAJ, and http://www.google.com/patents?id=-QEWAAAAEBAJ. The first two actually feel substantial and specific (probably too specific for Fototime to have been infringing); the third one is just a simple database schema and a flowchart, which is madness (though it, too, is so specific that it's unlikely that anyone was actually infringing).