开发者

logging system for nodejs and node-worker

开发者 https://www.devze.com 2023-01-31 12:29 出处:网络
nodejs logging system, I want a beautiful console logging and also can save to log file, and also fast, async will be bet开发者_JS百科ter.

nodejs logging system, I want a beautiful console logging and also can save to log file, and also fast, async will be bet开发者_JS百科ter.

The most difficult is , node-worker, which use std io to communicate with parent process, so if the logging system using std io, it can't work.


There are a lot of options given on this page, in the debugging section.


I have looked through many loggers, and I wasn't able to find a lightweight solution - so I decided to make a simple solution that is posted on github.

  • Saves the file
  • Gives you a pretty output (we all love that)

I hope this helps you out.

SETUP

https://github.com/bluejamesbond/Scribe.js

PS: If there are any problems, I would be obliged if you can fix it and then do a pull request. Otherwise, you are more than welcome to post as an issue.

SAMPLE OUTPUT TO CONSOLE

logging system for nodejs and node-worker

SAMPLE DIRECTORY SETUP

logging system for nodejs and node-worker

SAMPLE OUTPUT FILE

logging system for nodejs and node-worker

0

精彩评论

暂无评论...
验证码 换一张
取 消