Don't use that in prod, because it doesn't work in IE and it will cause your js to stop working.
In IE the 'console' object doesn't even exist if the developer tools aren't displayed, so if you use "console.log" in your program, your js will just throw an NPE.
Note that if you try closing the Developer Tools, 'console' is still declared for this page and all descendant pages. To test 'console.log' you need to avoid opening the devtools and open a new tabs.
I don't remember when exactly, but they fixed that at some point. I just ran this simple test in IE (without ever opening the dev tools) and got the alert: http://jsbin.com/hodavocuwu/1/edit
In IE the 'console' object doesn't even exist if the developer tools aren't displayed, so if you use "console.log" in your program, your js will just throw an NPE.
Note that if you try closing the Developer Tools, 'console' is still declared for this page and all descendant pages. To test 'console.log' you need to avoid opening the devtools and open a new tabs.