Skip to content

Commit 06ef5db

Browse files
wtrockiIvanGoncharov
authored andcommitted
Improve documentation for astFromValue (#2182)
1 parent 1a82c35 commit 06ef5db

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/utilities/astFromValue.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,11 @@ import {
2424
} from '../type/definition';
2525

2626
/**
27-
* Produces a GraphQL Value AST given a JavaScript value.
27+
* Produces a GraphQL Value AST given a JavaScript object.
28+
* Function will match JavaScript/JSON values to GraphQL AST schema format
29+
* by using suggested GraphQLInputType. For example:
30+
*
31+
* astFromValue("value", GraphQLString)
2832
*
2933
* A GraphQL type must be provided, which will be used to interpret different
3034
* JavaScript values.

0 commit comments

Comments
 (0)