Noel Rappin Writes Here

2012/09

Functions that return functions are the luckiest functions in the world

Here’s some JavaScript: var foo = function(a, b) { return a * b }; var bar = function(func) { return function() { return func.apply(this, arguments) }; }; baz = bar(foo); console.log(baz(2, 3)); What we have here is a function, bar, that both takes a function as an argument and returns a function as it’s result. It’s transforming the function passed to it into a different function. Okay, that’s cool in kind of an abstract way, but so what?

Master Space And Time Status Update

Here’s a quick status update on Master Space and Time With JavaScript, book 3… Short version: expect an early beta of about 1/3 of the book to be out in about a week. Longer version: Work is proceeding steadily, the current draft of just hit 30 pages toward a target of around 90, though about 10 of that is the same intro and outro that the other books have, so it’s more like 20 pages toward a target of 80.