1.0.2 • Published 9 years ago

debug-list v1.0.2

Weekly downloads
4
License
MIT
Repository
github
Last release
9 years ago

debug-list

Small utility for managing multiple visionmedia/debug

Installation

$ npm install debug-list --save

Usage

Example app.js:

var notepad = require('debug-list');

// fake app

notepad('booting %s', name);

notepad.add('http');
notepad.add('worker');
notepad.add('process');

http.createServer(function(req, res){
  notepad.http(req.method + ' ' + req.url);
  res.end('hello\n');
}).listen(3000, function(){
  notepad.http('listening');
});

// fake worker of some kind

require('./worker');
require('./process');

Example worker.js:

var notepad = require('debug-list');

setInterval(function(){
  notepad.worker('doing some work');
}, 1000);

Example process.js:

var debug = require('debug')('process');

setInterval(function(){
  debug('processing.... still works');
}, 1000);
1.0.2

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago