Skip to content

Commit

Permalink
fix(json-logs): use stringify option
Browse files Browse the repository at this point in the history
This forces the JSON output to be on a single line. Without it, it's not
easy to parse the logs.

Connects #47

See https://github.com/winstonjs/winston/blob/2.4.0/docs/transports.md#console-transport
  • Loading branch information
orangejulius committed Sep 1, 2018
1 parent 7ff7e6c commit fc702f1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ function CreateLogger( name, loggerOpts ){
new winston.transports.Console( {
colorize: pkgConfig.colorize,
json: pkgConfig.json,
stringify: true,
timestamp: pkgConfig.timestamp,
level: pkgConfig.level,
label: name
Expand Down

0 comments on commit fc702f1

Please sign in to comment.