+ 15

Annoying Console

Most WebGL scripts I see gets that annoying console covering 20% of the screen, saying «Three.webglrenderer». This is very useless and annoying. Anyone knows how to hide this console? (Not the <br> method, I want to hide the whole console) I hope someone can help, Joakim https://code.sololearn.com/WWY9cXN6OVBX/?ref=app

30th May 2018, 9:24 PM
Joakim Nyland
Joakim Nyland - avatar
3 Antworten
+ 18
try adding this line at the top of your Javascript code console.log=function(){} edit: found in - https://github.com/mrdoob/three.js/pull/5835 a nicer solution that allows you to make console.log() for debugging while blocking THREE logs: console.realLog = console.log; console.log = function () { if (arguments[0] != 'THREE.WebGLRenderer') console.realLog.apply (console, arguments); };
30th May 2018, 9:44 PM
Burey
Burey - avatar
+ 12
</JoakimNyland> great to hear :) i had my doubt tho as i tried this method some time ago in earlier versions of sololearn and it hasn't worked back then...
31st May 2018, 5:58 AM
Burey
Burey - avatar
+ 6
Burey Thanks a lot, that works very well:-)
31st May 2018, 5:46 AM
Joakim Nyland
Joakim Nyland - avatar