@@ -134,6 +134,8 @@ export class GraphQLSchema {
134
134
_subTypeMap : ObjMap < ObjMap < boolean >> ;
135
135
// Used as a cache for validateSchema().
136
136
__validationErrors : ?$ReadOnlyArray < GraphQLError > ;
137
+ // Referenced by execute()
138
+ __experimentalDeferFragmentSpreads : boolean ;
137
139
138
140
constructor ( config : $ReadOnly < GraphQLSchemaConfig > ) : void {
139
141
// If this schema was built from a source known to be valid, then it may be
@@ -161,6 +163,8 @@ export class GraphQLSchema {
161
163
this . astNode = config . astNode ;
162
164
this . extensionASTNodes = config . extensionASTNodes ;
163
165
166
+ this . __experimentalDeferFragmentSpreads =
167
+ config . experimentalDeferFragmentSpreads || false ;
164
168
this . _queryType = config . query ;
165
169
this . _mutationType = config . mutation ;
166
170
this . _subscriptionType = config . subscription ;
@@ -305,6 +309,18 @@ export type GraphQLSchemaValidationOptions = {|
305
309
* Default: false
306
310
*/
307
311
assumeValid ? : boolean ,
312
+
313
+ /**
314
+ *
315
+ * EXPERIMENTAL:
316
+ *
317
+ * If enabled, processed fields from fragment spreads with @defer directive
318
+ * are not returned from the iniital query and the respective data is returned
319
+ * in patches after the initial result from the synchronous query.
320
+ *
321
+ * Default: false
322
+ */
323
+ experimentalDeferFragmentSpreads ?: boolean ,
308
324
| } ;
309
325
310
326
export type GraphQLSchemaConfig = { |
0 commit comments