如何从 Express 应用程序中删除调试? [英] How to remove debugging from an Express app?
本文介绍了如何从 Express 应用程序中删除调试?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想删除调试模式.我正在使用 express
、redis
、socket.io
和 connect-redis
,但我不知道在哪里调试模式来自.
I would like to remove the debugging mode. I am using express
, redis
, socket.io
and connect-redis
, but I do not know where the debugging mode comes from.
有人有想法吗?
推荐答案
更新
完全去除调试使用:
var io = require('socket.io').listen(app, { log: false });
其中 app
是 node.js http server/express etc.
Where app
is node.js http server / express etc.
您忘了提及您也在使用 socket.io.这来自 socket.io.您可以通过配置禁用此功能:
You forgot to mention you are also using socket.io. This is coming from socket.io. You can disable this by configuration:
io.set('log level', 1); // reduce logging
这篇关于如何从 Express 应用程序中删除调试?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文