Package Exports
- verbosity
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (verbosity) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
verbosity
An augmented drop-in console replacement that supports logging levels.
Status
Developer
Help
Usage
Installation
npm install --save verbosity
Examples
Simply override the built in console object:
const console = require('../../index.js').createConsole({
outStream: process.stdout,
errorStream: process.stderr,
verbosity: 5
})
This will direct all console output to stderr, but silence 'info' and 'debug' messages.
const console = require('../../index.js').createConsole({
outStream: process.stderr,
verbosity: 3
})
console.log('Picked brown jacket...') // Printed
console.debug('Purple tie chosen...') // Not printed
console.warn("That tie doesn't go with that jacket.") // Printed
Or go mad with making up any number of custom console writers.
const myUberConsole = require('../../index.js').createConsole({
outStream: myFancyWriteableStream,
verbosity: 5
})
myUberConsole.panic('Core Flux Capacitor Meltdown!')
Documentation
Full documentation can be found at https://markgriffiths.github.io/verbosity/