@workpop/simple-logger
Dead simple logging utility for node.
Usage
Basic
import Logger from '@workpop/simple-logger';
const logger = new Logger('MYAPP');
logger.info('important information', 'and more');
logger.warn('some warning occurred')
logger.trace('something not very significant occurred');
logger.error('oh no!', new Error());
Enable / Disable
You can globally enable / disable ALL logger instances as follows:
import Logger from '@workpop/simple-logger';
const logger = new Logger('MYAPP');
Logger.disable();
logger.info('something');
Logger.enable();
logger.info('something else');