Before you quickly post with “RTFM” or with a bunch of links I have visited, I am fully aware of the documented reserved variable names not to use.
The best lists I could find are here:
http://es5.github.com/x7.html#x7.6.1.1
and
http://www.javascripter.net/faq/reserved.htm
What I am asking for are the variable names that are invalid on 1 or 2 browsers only.
For example I can define print but this will cause an error as print is already defined on the global scope window. Why isn’t this documented as a reserve keyword?
Is there a big list of variable names to avoid?
If you want a big list of browser-defined variables to extend the official list of reserved keywords, type the following into your console on an empty page (about:blank):
which will yield an Array of strings you definitely should not use. It includes
"print", too.Yet it will be browser-dependent, because some do not implement all the cool HTML5-drafted stuff that uses the
Windowinterface; e.g. you won’t find"Worker"in IE9,"openDatabase"in FF and so on. Also, it might not list legacy properties like"onload", altough you will be able to to get a property descriptor for it (and"onload" in window === true).