winston-logger
v1.0.1
Published
Create a winston logger using a simple API.
Downloads
37
Readme
winston-logger
Create a winston logger using a simple API.
Example
var Logger = require('winston-logger');
var logger = Logger({ console: true });
logger.info(..)
Here's an example development
option set:
{
"console" : true
}
And production
options:
{
"file" : true,
"console" : false,
"mail" : {
"to": "[email protected]",
"from": "[email protected]",
"level": "critical",
"host": "smtp.sendgrid.net",
"username": "sendgrid_user",
"password": "sendgrid_pass",
"ssl": false
},
"papertrail" : {
"host": "logs.papertrailapp.com",
"port": 10000,
"level": "error"
}
}
API
Logger(options)
Create a winston logger with provided transports in the options.
License
WWWWWW||WWWWWW
W W W||W W W
||
( OO )__________
/ | \
/o o| MIT \
\___/||_||__||_|| *
|| || || ||
_||_|| _||_||
(__|__|(__|__|