Here are some more things I have learnt whilst writing a free game:
1) Some programmers say that it is better to use the expression:
typeof objectProperty === 'undefined'
objectProperty === undefined
Also notice that the expression:
null == undefined
2) I have read that it is best not to use the 'caller' property of functions
4) I shorten some built-in function names like this:
Array.prototype.p = Array.prototype.push
I do not change the source code but make the changes in my 'minimising' scripts.
If you use a 'for in' loop on arrays, you will need to stop the alias appearing by using the 'hasOwnProperty()' function. Any libraries you use will need to do this too
5) If you miss out an element in a list of array elements, e.g. 'a = [1,,3]', then you get an element with a value of 'undefined'.
I typed this by mistake and got an error in my code
You can find more tips in the wiki of the British Bingo project on Sourceforge