I have this example code:
var foo = { self: this, init: function(){ self.doStuff(); }, doStuff: function(){ alert(\'doing
Because at the time you declare the object literal this is not a reference to the object, but to whatever the calling context is.
this