Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkGriffiths committed Feb 15, 2019
1 parent 0f733f2 commit 01695ee
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 31 deletions.
18 changes: 8 additions & 10 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,14 @@ const {
Console
} = console;
class Verbosity extends Console {
constructor(options = {}) {
const {
outStream,
errorStream,
verbosity,
timestamp,
namespace,
prefix
} = options;

constructor({
outStream,
errorStream,
verbosity,
timestamp,
namespace,
prefix
} = {}) {
const sOut = (ws => {
if (!ws.writable) {
throw new Error('Provided output stream must be writable');
Expand Down
18 changes: 8 additions & 10 deletions index.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,14 @@ const {
Console
} = console;
class Verbosity extends Console {
constructor(options = {}) {
const {
outStream,
errorStream,
verbosity,
timestamp,
namespace,
prefix
} = options;

constructor({
outStream,
errorStream,
verbosity,
timestamp,
namespace,
prefix
} = {}) {
const sOut = (ws => {
if (!ws.writable) {
throw new Error('Provided output stream must be writable');
Expand Down
6 changes: 3 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
"acorn": "^6.1.0",
"ava": "^1.2.1",
"documentation": "^9.1.1",
"documentation-theme-bespoke": "^0.4.8",
"documentation-theme-bespoke": "^0.4.9",
"gulp": "^4.0.0",
"gulp-better-rollup": "^3.4.0",
"gulp-rename": "^1.4.0",
Expand Down Expand Up @@ -143,4 +143,4 @@
]
]
}
}
}
22 changes: 16 additions & 6 deletions src/lib/verbosity.class.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const {format, inspect} = util
const {Console} = console
/**
* Generate a verbosity console
* @param {Object} options - Configuration options.
* @param {Object} options - Configuration options.
* @param {stream.writable} options.outStream - Stream to write normal output
* @param {stream.writable} options.errorStream - Stream to write error output
* @param {Number} options.verbosity - The verboseness of output:
Expand All @@ -28,11 +28,14 @@ const {Console} = console
* @return {Verbosity} Verbosity's console object.
*/
export default class Verbosity extends Console {
constructor(options = {}) {
const {
outStream, errorStream, verbosity, timestamp, namespace, prefix
} = options

constructor({
outStream,
errorStream,
verbosity,
timestamp,
namespace,
prefix
} = {}) {
const sOut = (ws => {
if (!ws.writable) {
throw new Error('Provided output stream must be writable')
Expand Down Expand Up @@ -221,6 +224,13 @@ export default class Verbosity extends Console {
* @param {String} msg The debug message to log.
* @param {...String} args Additional arguments to log.
*/

/**
* [debug description]
* @param {[type]} msg [description]
* @param {...[type]} args [description]
* @return {[type]} [description]
*/
debug(msg, ...args) {
this.route('debug', msg, ...args)
}
Expand Down

0 comments on commit 01695ee

Please sign in to comment.