A simple wrapper around console
logging functions (for Node.js)
Just colors output and prepends it with formatted date.
$ yarn add simple-color-logger
const logger = require('simple-color-logger')('DD.MM.YYYY HH:mm:ss'/*default*/)
logger.error('error')
logger.info('info')
logger.fyi('fyi')
logger.log('log')
logger.warn('warn')
Approximate output:
22.06.2017 13:34:18 error // red
22.06.2017 13:34:18 info // green
22.06.2017 13:34:18 fyi // gray
22.06.2017 13:34:18 log // no coloring
22.06.2017 13:34:18 warn // yellow
22.06.2017 13:34:18 info // green
22.06.2017 13:34:18 fyi // gray
22.06.2017 13:34:18 log // no coloring
22.06.2017 13:34:18 warn // yellow