Helpful Links on JavaScript Closures
Posted in Development
Closures are a very powerful concept. They are easy to understand conceptually, but the devil is in the details, as the saying goes.
For example, closures can cause leaks in Internet Explorer when they serve as even handlers. Closures can “freeze” or “remember” parameters and variables of the parent function even after it terminates.
Below is a list of helpful posts and articles to help you understand closures (in order of preference):
- Mark Wubben has a nice short overview in Getting Funky With Scopes and Closures
- JavaScript Closures — a very thorough yet very wordy discussion. If you understand the life cycle of the Activation/Variable object, closures will be your friends. Guaranteed!
- What are closures?
- Understanding and Solving Internet Explorer Leak Patterns This is a must read. Period.
- In Private Members in JavaScript Douglas Crockford shows how to create private class members and methods with closures.
- Private Static Members in JavaScript — another excellent discussion along the lines of the previous bullet point.

britney
on April 4, 2006
Thanks for the links just started with Java programming and love what I ve learned so far and these links make me love it even more!