Created
July 27, 2016 15:36
-
-
Save deepakshrma/9ed353dbf12744c3d512cd376976662a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
var winstonConf = {}; | |
function _define(config, name, value) { | |
Object.defineProperty(config, name, { | |
value: value, | |
enumerable: true, | |
writable: false, | |
configurable: false | |
}); | |
} | |
_define(winstonConf, 'config', { | |
defaults: { | |
levels: { | |
debug: 0, | |
info: 1, | |
warn: 2, | |
error: 3 | |
}, | |
colors: { | |
debug: 'cyan', | |
info: 'green', | |
warn: 'yellow', | |
error: 'red' | |
} | |
}, | |
env: { | |
production: { | |
level: 'error', | |
handleExceptions: true, | |
json: false, | |
colorize: true | |
}, | |
development: { | |
level: 'info', | |
handleExceptions: false, | |
json: false, | |
colorize: true | |
}, | |
worker: { | |
level: 'info', | |
handleExceptions: false, | |
json: false, | |
colorize: true | |
} | |
} | |
}); | |
module.exports = winstonConf.config; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment