console.log is a debug statement used in Javascript code.
However is not supported in older browsers like IE8...
If you forget to remove then, IE8 will crash and burn...
It may also affect performance, although that is usually negligible...
If you forget to remove then, IE8 will crash and burn...
It may also affect performance, although that is usually negligible...
if (typeof console == "undefined") { console = { log: function() {} }; };
That is not quite correct. IE8 (and IE9 I believe) support `console.log`, but only when the developer tools are open.
Needless to say, it is rather frustrating.