From 2754c4bc0d25e8fc46a3d2daa2aa840ed8eb27d8 Mon Sep 17 00:00:00 2001 From: Loic Doubinine Date: Wed, 30 May 2018 14:42:45 +0200 Subject: [PATCH] Rename fieldMiddleware to middleware Changed in yoga: https://github.com/prismagraphql/graphql-yoga/pull/276 --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index fb753c9f..abd1fe18 100644 --- a/README.md +++ b/README.md @@ -84,7 +84,7 @@ const resolvers = { const server = new GraphQLServer({ typeDefs, resolvers, - fieldMiddleware: [authMiddleware, metricsMiddleware], + middleware: [authMiddleware, metricsMiddleware], documentMiddleware: [], }) server.start(() => console.log('Server is running on localhost:4000')) @@ -135,7 +135,7 @@ function applyMiddleware( ### Can I use GraphQL Middleware without GraphQL Yoga? -Yes. Nevertheless, we encourage you to use it in combination with Yoga. Combining the power of `fieldMiddleware` that GraphQL Middleware offers, with `documentMiddleware` which Yoga exposes, gives you unparalleled control over the execution of your queries. +Yes. Nevertheless, we encourage you to use it in combination with Yoga. Combining the power of `middleware` that GraphQL Middleware offers, with `documentMiddleware` which Yoga exposes, gives you unparalleled control over the execution of your queries. ### How does GraphQL Middleware compare to `directives`?