winstonflight

1.0.5 • Public • Published

winstonflight

Build Status Coverage Status

A winston wrapper to enable adding transports by config

Example

const transports = [{
    "type": "file",
    "options": {
        "level": "error",
        "filename": "error.log"
    }
}, {
    "type": "daily-rotate-file",
    "options": {
        level: 'info',
        "filename": "bi-%DATE%.log",
        "datePattern": "YYYYMMDD"
    }
}];

const logger = winston.createLogger({
    level: 'info',
    transports: winstonFlight(winston, transports)
});

License

MIT

Readme

Keywords

Package Sidebar

Install

npm i winstonflight

Weekly Downloads

29

Version

1.0.5

License

MIT

Unpacked Size

6.03 kB

Total Files

3

Last publish

Collaborators

  • rockie