var bodyParser = require('koa-bodyparser');
var koa = require('koa');
var app = new koa();
app.use(bodyParser());
app.use(function(ctx, next) {
// the parsed body will store in this.request.body
// if nothing was parsed, body will be an empty object {}
ctx.body = ctx.request.body;
});
app.listen(3000);
Once the app server is running if I send a POST request with some data I just get an empty object returned?
Hi,
The usage example for 3.x doesn't seem to work?
Once the app server is running if I send a POST request with some data I just get an empty object returned?