diff --git a/README.md b/README.md index e23f644f..ff728af8 100644 --- a/README.md +++ b/README.md @@ -122,9 +122,7 @@ const router = new koaRouter(); const PORT = 3000; // koaBody is needed just for POST. -app.use(koaBody()); - -router.post('/graphql', graphqlKoa({ schema: myGraphQLSchema })); +router.post('/graphql', koaBody(), graphqlKoa({ schema: myGraphQLSchema })); router.get('/graphql', graphqlKoa({ schema: myGraphQLSchema })); app.use(router.routes());