epha-log
v0.3.28
Published
Log with service, version and levels
Downloads
19
Readme
Log
Get started
var log = require("epha-log");
/*
* Configuration of logger
* @params {
* service: (string) optional
* version: (string) optional
* type: (string) optional, default module
* transports: (array) optional [{
* level: ["ERROR","WARN","INFO","DEBUG","TRACE","TIME","DOING"], //default
* url: "track.com"
* }]
* }
*/
log = log({
service: "moduleX",
version: "0.1.0"
});
log.info("group", "message", "detail", "payload");
Console
$ [email protected] | INFO | group | message { arg3:"detail" } { arg4:"payload" }
Test example
npm test