body parser for koa extend.
$ npm install @koex/body
// See more in test
import onerror from '@koex/onerror';
import bodyParser from '@koex/body';
import * as router from '@koex/router';
import * as Koa from 'koa';
const app = new Koa();
app.use(onerror());
app.use(bodyParse());
app.use(router.post('/', ctx => {
ctx.body = ctx.request.body;
}));
app.listen(8000, '0.0.0.0', () => {
console.log('koa server start at port: 8000');
});