@etrainu/express-logger-middleware

Express request logging middleware built using bunyan and config.

Stats

StarsIssuesVersionUpdatedCreatedSize
@etrainu/express-logger-middleware
1.2.02 years ago3 years agoMinified + gzip package size for @etrainu/express-logger-middleware in KB

Readme

#etrainu-logger-middleware

To be used with an express router.

// Sample use
import * as config from 'config';
import logMiddleware from './logger';

const bunyan = {
  name: 'appName', // config.get('param')
  streams: [{
    level: 'logLevel',
    stream: process.stdout,
  }],
};

/** 
  router.use(
    logMiddleware({ config: 'test', logger: bunyan, });
  );
*/

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.