Multiple log files with Winston?
问题 We'd like to use Winston for our logging in Node.js. But, we can't figure out how to have two log files: one for just errors, and one for everything else. Doing this the naive way doesn't work, however: adding multiple winston.transports.File transports gives an error. Others have run into this problem, with vague hints of a solution, but no real answer. Any ideas? 回答1: I just sent a pull request that allows using multiple File transports in one logger. https://github.com/flatiron/winston