NodeJS Logger: winston.transports.DailyRotateFile is not a function
问题 I'm writing a rest api with NodeJS and express and I'm using express-winston to log accesses and erros. But I want to separate de log daily. Like in this post I'm trying to do so with winston.transports.DailyRotateFile. A piece of code below. api.use(expressWinston.logger({ transports: [ new winston.transports.DailyRotateFile({ name: 'file', datePattern: '.yyyy-MM-ddTHH', filename: path.join(__dirname, "log-access", "log_file.log") }) ] })); Then I receive the error: winston.transports