0

I made an app that use socket.io. It's time to put in production. Before that, i want to remove or disable all socket.io error log in Client Side( the browser of user, So by inspecting console, he will not see the error).

Error is available at this link below

https://i.stack.imgur.com/PMDib.jpg

Rehum
  • 534
  • 5
  • 14
  • Does this answer your question? [How to quickly and conveniently disable all console.log statements in my code?](https://stackoverflow.com/questions/1215392/how-to-quickly-and-conveniently-disable-all-console-log-statements-in-my-code) – Lawrence Cherone May 30 '21 at 01:25
  • Thanks. The link you provided give me an idea. `window['console']['error'] = function(){};` But I notice that it's erased. Socket.io still logging error. – Rehum May 30 '21 at 01:57
  • as long as its set before socket.io runs then it wont output https://playcode.io/774681/ – Lawrence Cherone May 30 '21 at 02:11

1 Answers1

0
console['error'] = function(){}

did the job before all others scripts. Thanks

Rehum
  • 534
  • 5
  • 14