
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
graceful-console
Advanced tools
Dectorator console module that adds color functionality, formatting, sorting, etc..
Decorator console module that adds color, formatting, sorting, etc.. to the node console.
The new console gives you more control. More colors. Line Numbers. Sorting. Etc... Contribute!
// Set a global variable called scribe
global.scribe = require('graceful-console');
// Use the global instance to log
scribe.tag('test').log('the frog jumped the boat');
scribe.warn({frog:1, water: 0});
scribe.error('it drowned');
scribe.tag('Sort Frog Array').sort(true).log(['Frog1', 'Frog3', 'Frog2']);
Drum role please...

Use NPM to install npm install graceful-console --save
Last step:
global.scribe = require('graceful-console');
###scribe.settings(obj), scribe.options(obj)
Settings sets these options till they are unset. Options sets these options for the immediate next log, info, warn, error, critical, etc.
opts Choose the scribe options: write path, stack, time, and/or lvl.
write: path dictates where scribe should output a scribe log file too.isStack: dictates weather or not to show line numbers and file names. This is resource intensive. Dont enable in production.isTime: dictates weather or not to show a time stamp.maxLvl: dictates how much information you want scribe to print: do you want to print all scribe messages or just errors? (scribe.ERROR || scribe.CRITICAL << scribe.WARN << scribe.ALL || scribe.INFO)label: For advanced users! Instead use the alias scribe#warn, scribe#error, scribe#info, and scribe#critical.lvl: For advanced users! Instead use the alias scribe#warn, scribe#error, scribe#info, and scribe#critical.sort: Do not use! Instead use the alias scribe#sort.tag: Do not use! Instead use the alias scribe#tag.###scribe.log(str), scribe.error(str), scribe.info(str), scribe.warn(str), scribe.critical(str)
Takes a string str as the output tag. Prints str to stdout with newline. Eats the current options such as tag and sort.
scribe.log('I have a frog.');
scribe.info('He is there.');
scribe.warn('The frog might jump the boat.');
scribe.error('The frog jumped the boat.');
scribe.critical('The frog did not die.');
###scribe.tag(str)
Takes a string str as the output tag. The next log, error, warn, info will be tagged with the str.
scribe.tag('test').log('the frog jumped the boat');
###scribe.sort(arg)
Takes a function or a boolean arg. The next log, error, warn, info will be sorted.
scribe.tag('Sort Test Array').sort().log([1, 3, 2]);
scribe.tag('Sort Test Object').sort().log({1: 'a', 3: 'c', 2: 'b'});
scribe.tag('Sort Test Function Inveser').sort(function(a, b) { return b.value.charCodeAt(0) - a.value.charCodeAt(0)}).log({1: 'a', 3: 'c', 2: 'b'});
###scribe.break(str)
Prints a new line.
scribe.break();
###scribe.chunk(func)
Takes a function func where every call to scribe chunks text using spacing and pretty formatting.
scribe.tag('chunk').chunk(() => {
scribe.log(true);
scribe.log(false);
scribe.tag('string').log('A string');
scribe.tag('printf').log('A manipulated string (%s) with number: %d', 'apple', 42);
scribe.tag('number').log(1);
scribe.log(1);
scribe.log(true);
scribe.log({me:1});
scribe.log([1,2,3]);
scribe.error([1,2,3]);
scribe.error('');
scribe.error(new Error("Errorrrs"));
scribe.tag('Sort Test Array').sort().log([1, 3, 2]);
scribe.tag('Sort Test Object').sort().log({1: 'a', 3: 'c', 2: 'b'});
scribe.tag('Sort Test Function Inveser').sort(function(a, b) { return b.value.charCodeAt(0) - a.value.charCodeAt(0) }).log({1: 'a', 3: 'c', 2: 'b'});
});
###scribe.dir, scribe.assert, scribe.time, scribe.timeEnd
Alias to the console equivalent (i.e. console.dir, console.assert, etc). Refer to Node documentation for behavior https://nodejs.org/api/scribe.html#scribe_scribe_log_data
MIT
FAQs
Dectorator console module that adds color functionality, formatting, sorting, etc..
The npm package graceful-console receives a total of 5 weekly downloads. As such, graceful-console popularity was classified as not popular.
We found that graceful-console demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.