Skip to content

Commit 740b7fa

Browse files
IvanGoncharovleebyron
authored andcommitted
Export 'GraphQLSchemaConfig' & 'GraphQLDirectiveConfig' types (#1193)
1 parent 87c1bc3 commit 740b7fa

File tree

4 files changed

+8
-2
lines changed

4 files changed

+8
-2
lines changed

src/index.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ export type {
138138
GraphQLNullableType,
139139
GraphQLNamedType,
140140
Thunk,
141+
GraphQLSchemaConfig,
141142
GraphQLArgument,
142143
GraphQLArgumentConfig,
143144
GraphQLEnumTypeConfig,
@@ -163,6 +164,7 @@ export type {
163164
GraphQLScalarTypeConfig,
164165
GraphQLTypeResolver,
165166
GraphQLUnionTypeConfig,
167+
GraphQLDirectiveConfig,
166168
} from './type';
167169

168170
// Parse and operate on GraphQL language source files.

src/type/directives.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ export class GraphQLDirective {
7676
}
7777
}
7878

79-
type GraphQLDirectiveConfig = {
79+
export type GraphQLDirectiveConfig = {
8080
name: string,
8181
description?: ?string,
8282
locations: Array<DirectiveLocationEnum>,

src/type/index.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ export {
1414
GraphQLSchema,
1515
} from './schema';
1616

17+
export type { GraphQLSchemaConfig } from './schema';
18+
1719
export {
1820
// Predicates
1921
isType,
@@ -84,6 +86,8 @@ export {
8486
DEFAULT_DEPRECATION_REASON,
8587
} from './directives';
8688

89+
export type { GraphQLDirectiveConfig } from './directives';
90+
8791
// Common built-in scalar instances.
8892
export {
8993
isSpecifiedScalarType,

src/type/schema.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ export class GraphQLSchema {
220220

221221
type TypeMap = ObjMap<GraphQLNamedType>;
222222

223-
type GraphQLSchemaConfig = {
223+
export type GraphQLSchemaConfig = {
224224
query?: ?GraphQLObjectType,
225225
mutation?: ?GraphQLObjectType,
226226
subscription?: ?GraphQLObjectType,

0 commit comments

Comments
 (0)