code: function initialize() {
    var flags = [];
  
    Object.keys( levels ).forEach(function( type, level ) {
      var method = type.toLowerCase();
      exports[ method ] = log.bind( exports, type, level, false );
      exports[ method ].json = log.bind( exports, type, level, true );
      if ( new RegExp( '\\b' + type + '\\b', 'i' ).test( env ) ) {
        flags.push( level );
      }
    });
  
    loglevel = Math.min.apply( Math, flags );
  }
docs: set loglevel based on NODE_DEBUG env variable and create exported methods