level-logger

2.0.0 • Public • Published

Level Logger

Build StatusJavaScript Style Guide

A simple logger module wrapping the debug module.

It generates an object containing logging functions provided through the debug for the following log levels:

  • debug
  • info
  • warn
  • error
  • fatal

prefixing the module name with the corresponding <log level>:

For convenience reasons the generated object also holds a reference to console.trace.

Installation

npm install level-logger

Usage

const log = require('level-logger')('my-module')
 
log.debug('debug message')
log.info('info message')
log.warn('warning message')
log.error('error message')
log.fatal('fatal message')

License

MIT

Dependents (3)

Package Sidebar

Install

npm i level-logger

Weekly Downloads

0

Version

2.0.0

License

MIT

Last publish

Collaborators

  • heitzerj.dpm
  • timmyjs.dpm