Skip to content

Commit ee4d93f

Browse files
helferleebyron
authored andcommitted
update graphql function signature to 0.5.0 (graphql#28)
People kept running into problems with this, because documentation wasn't updated.
1 parent 6ef105f commit ee4d93f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

site/docs/APIReference-GraphQL.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,14 +146,16 @@ graphql(
146146
schema: GraphQLSchema,
147147
requestString: string,
148148
rootValue?: ?any,
149+
contextValue?: ?any,
149150
variableValues?: ?{[key: string]: any},
150151
operationName?: ?string
151152
): Promise<GraphQLResult>
152153
```
153154
154155
The `graphql` function lexes, parses, validates and executes a GraphQL request.
155156
It requires a `schema` and a `requestString`. Optional arguments include a
156-
`rootValue`, which will get passed as the root value to the executor,
157+
`rootValue`, which will get passed as the root value to the executor, a `contextValue`,
158+
which will get passed to all resolve functions,
157159
`variableValues`, which will get passed to the executor to provide values for
158160
any variables in `requestString`, and `operationName`, which allows the caller
159161
to specify which operation in `requestString` will be run, in cases where

0 commit comments

Comments
 (0)