JavaScript Patterns

An interesting blog detailing some useful JavaScript design patterns (and anti-patterns) is here:

http://www.jspatterns.com/

The code reuse patterns are particularly interesting for anyone learning JavaScript that has a “classical” object-oriented programming background (e.g. C++, Java).  Although, if you are trying to use classical inheritance with JavaScript, you are probably doing it wrong.  To quote Douglas Crockford:

I have been writing JavaScript for 8 years now, and I have never once found need to use an uber function. The super idea is fairly important in the classical pattern, but it appears to be unnecessary in the prototypal and functional patterns. I now see my early attempts to support the classical model in JavaScript as a mistake.

He offers a lesson in Prototypal Inheritance here:

http://javascript.crockford.com/prototypal.html

Here are some other links about JavaScript inheritance: