Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add how to colorize output in the custom formatter example #989

Merged
merged 1 commit into from
Sep 27, 2017
Merged

Add how to colorize output in the custom formatter example #989

merged 1 commit into from
Sep 27, 2017

Conversation

rgoliveira
Copy link
Contributor

It took me a while to figure out why my format function wasn't colorizing anything in the output. Thought this might make the example clearer and more complete.

Open to any suggestions/feedback.

@rgoliveira rgoliveira changed the title [RFC] Add how to colorize output in the custom formatter example Add how to colorize output in the custom formatter example Mar 10, 2017
Copy link
Member

@indexzero indexzero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution!

@indexzero indexzero merged commit afffe1f into winstonjs:master Sep 27, 2017
@line0
Copy link

line0 commented Sep 29, 2017

Isn't that wrong though? The colorize function is in winston.config, not in the options object of a transport.

@indexzero
Copy link
Member

You are correct. I've been out of this code so long I did not notice. [email protected] will be released on Monday. This can be fixed up on the 2.x branch after that.

@rgoliveira
Copy link
Contributor Author

Ah, my bad. I might've typed that out from memory after a long night of bug squashing 😅

cjbarth pushed a commit to cjbarth/winston that referenced this pull request Aug 22, 2018
* commit 'dc74db60b8d46475fce04bab1e0c31abe5201e09': (34 commits)
  [dist] Maintenance release. 2.4.3
  [Winston 2.x] Decycle circular `Error` instances (winstonjs#1307)
  [dist] Maintenance release. 2.4.2
  [dist] Add .gitattributes file.
  [fix] Backport winstonjs#1281 onto 2.x for maintenance.
  [dist] Add ignores from 3.x for easier maintenance switching.
  fix: clone() cloning prototype's custom methods (winstonjs#1086)
  Don't swallow Error message/stack when using formatter (winstonjs#1188)
  [dist] Add package-lock.json
  Update http.js - Add support for headers
  fix 2.x readme (fixes winstonjs#1179)
  [dist] Maintenance release. 2.4.1
  Always pass a function to fs.close (winstonjs#1227)
  Update documentation for the `stringify` option
  [dist] Version bump. 2.4.0
  [fix] Correct documentation mistake in 2.x
  Add how to colorize output in the custom formatter example (winstonjs#989)
  [fix] Container.add() 'filters' and 'rewriters' option passing to logger (winstonjs#1036)
  Fixed working of "humanReadableUnhandledException" parameter when additional data is added in meta (winstonjs#1066)
  Added filtering by log level (winstonjs#1040)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants