@cotep/std-nice is a tool to log objects in Node.js for dev environnement.
std-nice requires Node.js v8+ to run.
Install and start to code.
$ npm i --save @cotep/std-niceconst stdnice = require('@cotep/std-nice');
const mongoose = require('mongoose');
const obj = {
_id: mongoose.Types.ObjectId('4edd40c86762e0fb12000003'),
messages: [{
type : 1,
value: "fefzfzefzef",
}, {
type : 0,
value: "aaaaaaaaaa",
}],
};
obj.reference = obj;
stdnice.sd(obj);
stdnice.sd([]);
stdnice.sd(42);import stdnice from '@cotep/std-nice';
const obj = {
messages: [{
type : 1,
value: "fefzfzefzef",
}, {
type : 0,
value: "aaaaaaaaaa",
}],
};
stdnice.sd(obj);In your index.js :
global.LOG = require('@cotep/std-nice');In foo.js :
const messages: [{
type : 1,
value: "fefzfzefzef",
}, {
type : 0,
value: "aaaaaaaaaa",
}];
global.LOG.sd(messages);std-nice is currently extended with the following plugins.
| Plugin | Github |
|---|---|
| Colors | https://github.com/marak/colors.js/ |
g.neut a.emilien
MIT

