Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

depugger

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

depugger

small debugging utility

  • 0.1.3
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-50%
Maintainers
1
Weekly downloads
 
Created
Source

node-depugger

Build Status

NPM

NPM

Depugger is a small lib that provides a debugging utility.

depugger([debug, [name]]), depugger(options)

depugger returns a function that supports all of the util.format features and outputs debug messages based on the initial configuration.

  • debug: specifies if logged messages should be outputted, optional, default: false
  • name: a category key that will prepend every message, optional, default: ""
  • options: options hash that can be used to submit all of the above parameters at once
var depugger = require('depugger');

var debug = depugger(true, 'fooDebugger');

debug('foo');
debug('bar "%s"', 'bax');
debug('spam %d eggs', 10);

//output to console:
//[fooDebugger] foo
//[fooDebugger] bar "bax"
//[fooDebugger] spam 10 eggs

Alternatively all parameters can be specified via an options hash:

var depugger = require('depugger');

var debug = depugger({debug: true, name: 'fooDebugger'});

debug('foo');
debug('bar "%s"', 'bax');
debug('spam %d eggs', 10);

//output to console:
//[fooDebugger] foo
//[fooDebugger] bar "bax"
//[fooDebugger] spam 10 eggs

Keywords

FAQs

Package last updated on 11 Nov 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc