nl_tokens: Configured formatter to check for env and key words ( console and json )
pl_tokens: function configuredFormatter ( options = { } ) { let { typeFormat } = options ; if ( typeFormat === undefined ) { if ( process . env . NODE_ENV === 'development' || process . env . NODE_ENV === 'dev' ) { typeFormat = 'console' ; } else { typeFormat = 'json' ; } } if ( typeFormat === 'json' ) { return combine ( timestamp ( ) , addMetaFormat ( options ) , jsonFormat ) ; } if ( typeFormat === 'console' ) { return combine ( timestamp ( ) , colorize ( ) , consoleFormat ) ; } throw <mask> Error ( ` ${ typeFormat } ` ) ; }