IE 10: debug console (F12) changes behavior

I have a very strange problem: I am trying to debug a (F12) web application in IE 10. When the console is disabled, the problem is active. As soon as the console turns on (off) once, the problem disappears.

What will change the console in the rendering engine or the DOM tree? Is there a way to configure the console automatically?

Without console: Screenshot

With console (turns on for a couple of seconds): Screenshot

Please let me know if you would like more information on my part.

+4
source share
1 answer

This is often the result of an untested console.log in a script. Make sure to window.console code to the console before checking if window.console .

 var someVar = 1234; //Fatal JS error, when devtools are closed: console.log(someVar); //Safely checked! if (window.console) console.log(someVar); 
+5
source

Source: https://habr.com/ru/post/1499305/


All Articles