snakelog

1.0.2 • Public • Published

snakelog

simple logger for log4js.

For use:

var Snakelog = require('snakelog');
var snakelog1 = new Snakelog(); //Config defaults to the console
var snakelog2 = new Snakelog({appenders: [{type: 'file', filename: '/var/log/applog'}]}); //Config for writing to file (see log4js docs)
snakelog1.info('information message ');
snakelog2.setLevel('WARN');
snakelog2.info('information message');//The file will not be written because the level is higher

Readme

Keywords

Package Sidebar

Install

npm i snakelog

Weekly Downloads

0

Version

1.0.2

License

ISC

Last publish

Collaborators

  • snakebot