Skip to content

Commit 45ecb53

Browse files
authored
Merge extendType functionality changes from #1322 (#1373)
* Extend the extend functionality * Fix flowtype * Extract logic from _makeInputValues to its own function * Fix lint and minor refactors * Fix type error due to copy & paste * Fix array syntax * Fix test more verbose * Removed unnecessary check * Extend directive * Moved new tests into existing tests * Fix lint errors * Added missing description * fix enum value error test
1 parent 43c0d46 commit 45ecb53

File tree

4 files changed

+558
-38
lines changed

4 files changed

+558
-38
lines changed

src/type/definition.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -989,6 +989,7 @@ export class GraphQLUnionType {
989989
name: string;
990990
description: ?string;
991991
astNode: ?UnionTypeDefinitionNode;
992+
extensionASTNodes: ?$ReadOnlyArray<ObjectTypeExtensionNode>;
992993
resolveType: ?GraphQLTypeResolver<*, *>;
993994

994995
_typeConfig: GraphQLUnionTypeConfig<*, *>;
@@ -1081,6 +1082,7 @@ export class GraphQLEnumType /* <T> */ {
10811082
name: string;
10821083
description: ?string;
10831084
astNode: ?EnumTypeDefinitionNode;
1085+
extensionASTNodes: ?$ReadOnlyArray<ObjectTypeExtensionNode>;
10841086

10851087
_values: Array<GraphQLEnumValue /* <T> */>;
10861088
_valueLookup: Map<any /* T */, GraphQLEnumValue>;
@@ -1230,6 +1232,7 @@ export class GraphQLInputObjectType {
12301232
name: string;
12311233
description: ?string;
12321234
astNode: ?InputObjectTypeDefinitionNode;
1235+
extensionASTNodes: ?$ReadOnlyArray<ObjectTypeExtensionNode>;
12331236

12341237
_typeConfig: GraphQLInputObjectTypeConfig;
12351238
_fields: GraphQLInputFieldMap;

0 commit comments

Comments
 (0)