This is actually not an technical issue of debug.
I am using debug myself in all my projects (only server side at the moment), but i am wondering how you guys use debug in your projects and how is it intended to use by the creators?
Some questions:
Thanks
cheers
Do you create different debug instances for different log levels / severities?
Ya, sure, if that's what you want to do. I usually tend to just have 1 debug() instance per module though.
How do you create and maintain these different log levels? In a central module? global?
Just var debug = require('debug')('some-scope'); at the top of each module.
Do you mix debug with another logging module like winston or bunyan?
Nope.
If so, why? If not, why?
No because this is meant to be a debugging utility, not a logger.
"debug" for modules and libraries and other logging modules like winston or bunyan in your running apps?
I'm not really sure what you mean with that question...
Hope that helps. Cheers!
Most helpful comment
Ya, sure, if that's what you want to do. I usually tend to just have 1 debug() instance per module though.
Just
var debug = require('debug')('some-scope');at the top of each module.Nope.
No because this is meant to be a debugging utility, not a logger.
I'm not really sure what you mean with that question...
Hope that helps. Cheers!