In JavaScript, the standard rules for code formatting don't seem to cut it. You still end up with messes of });});
all over the place and I don't believe I even know of established rules for the correct indention of anonymous functions declared as arguments to other functions.
In short, I have trouble reading my own JavaScript, and I bet I'm not alone.
I think the idea that I am coming around to is to just not define functions within other functions. Write every function with a name and as a child to the script tag. When you need to pass functions around, use their names. Of course, this makes it a lot harder to use closures [edit: you cannot use closures at all if you write your code that way]. Also, this might cause problems with memory management?
Anyone else have thoughts on this?