koa-logtown
v2.4.5
Published
Logging middleware for koa with logtown underneath
Downloads
3
Maintainers
Readme
koa-logtown
Development style logger middleware for Koa that leverages logtown.
The middleware is very similar to koa-logger
, but console.log
was replaced with logtown
functions calls.
<-- GET /
--> GET / 200 835ms 746b
<-- GET /
--> GET / 200 960ms 1.9kb
<-- GET /users
--> GET /users 200 357ms 922b
<-- GET /users?page=2
--> GET /users?page=2 200 466ms 4.66kb
Installation
npm install koa-logtown logtown --save
or
yarn add koa-logtown logtown
Usage
const koaLogger = require('koa-logtown');
const Koa = require('koa');
const app = new Koa();
app.use(koaLogger());
License
koa-logtown is released under the MIT license.