Archive for July, 2008

Lexical Closures are Handy

Posted in Development by MB on 07/20/08

I wrote previously that I would write about a handy trick in JavaScript known as a “lexical closure”.
This article has a great definition of a lexical closure: http://www.brockman.se/writing/method-references.html.utf8.
I quote…

Essentially, a closure, or lexical closure, is a function f coupled with a snapshot of its lexical environment (i.e., the non-local variable bindings used in its body).
Hence, [...]

« Older Entries Newer Entries »