Skip to content

Latest commit

 

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

debug-flags NPM version Build Status

Development Dependency status

Easy way to check the environment variable NODE_DEBUG for the presence of the nested flags.

Install

$ npm install --save debug-flags

Usage example

// suppose NODE_DEBUG="app lib:func"
var isDebugEnabled = require('debug-flags');

isDebugEnabled('app'); // => true
isDebugEnabled('app:something:nested'); // => true
isDebugEnabled('flag'); // => false
isDebugEnabled('lib'); // => false
isDebugEnabled('lib:func'); // => true
isDebugEnabled('lib:func:xxx'); // => true

Have fun!

About

Easy way to check the environment variable NODE_DEBUG for the nested flags.

Resources

Stars

1 star

Watchers

10 watching

Forks

Releases

Packages

Used by

Contributors

Languages