@@ -2,7 +2,6 @@ import { devAssert } from '../jsutils/devAssert.js';
2
2
import { didYouMean } from '../jsutils/didYouMean.js' ;
3
3
import { identityFunc } from '../jsutils/identityFunc.js' ;
4
4
import { inspect } from '../jsutils/inspect.js' ;
5
- import { instanceOf } from '../jsutils/instanceOf.js' ;
6
5
import { keyMap } from '../jsutils/keyMap.js' ;
7
6
import { keyValMap } from '../jsutils/keyValMap.js' ;
8
7
import { mapValue } from '../jsutils/mapValue.js' ;
@@ -78,7 +77,7 @@ export function assertType(type: unknown): GraphQLType {
78
77
* There are predicates for each kind of GraphQL type.
79
78
*/
80
79
export function isScalarType ( type : unknown ) : type is GraphQLScalarType {
81
- return instanceOf ( type , GraphQLScalarType ) ;
80
+ return type instanceof GraphQLScalarType ;
82
81
}
83
82
84
83
export function assertScalarType ( type : unknown ) : GraphQLScalarType {
@@ -89,7 +88,7 @@ export function assertScalarType(type: unknown): GraphQLScalarType {
89
88
}
90
89
91
90
export function isObjectType ( type : unknown ) : type is GraphQLObjectType {
92
- return instanceOf ( type , GraphQLObjectType ) ;
91
+ return type instanceof GraphQLObjectType ;
93
92
}
94
93
95
94
export function assertObjectType ( type : unknown ) : GraphQLObjectType {
@@ -100,7 +99,7 @@ export function assertObjectType(type: unknown): GraphQLObjectType {
100
99
}
101
100
102
101
export function isInterfaceType ( type : unknown ) : type is GraphQLInterfaceType {
103
- return instanceOf ( type , GraphQLInterfaceType ) ;
102
+ return type instanceof GraphQLInterfaceType ;
104
103
}
105
104
106
105
export function assertInterfaceType ( type : unknown ) : GraphQLInterfaceType {
@@ -113,7 +112,7 @@ export function assertInterfaceType(type: unknown): GraphQLInterfaceType {
113
112
}
114
113
115
114
export function isUnionType ( type : unknown ) : type is GraphQLUnionType {
116
- return instanceOf ( type , GraphQLUnionType ) ;
115
+ return type instanceof GraphQLUnionType ;
117
116
}
118
117
119
118
export function assertUnionType ( type : unknown ) : GraphQLUnionType {
@@ -124,7 +123,7 @@ export function assertUnionType(type: unknown): GraphQLUnionType {
124
123
}
125
124
126
125
export function isEnumType ( type : unknown ) : type is GraphQLEnumType {
127
- return instanceOf ( type , GraphQLEnumType ) ;
126
+ return type instanceof GraphQLEnumType ;
128
127
}
129
128
130
129
export function assertEnumType ( type : unknown ) : GraphQLEnumType {
@@ -137,7 +136,7 @@ export function assertEnumType(type: unknown): GraphQLEnumType {
137
136
export function isInputObjectType (
138
137
type : unknown ,
139
138
) : type is GraphQLInputObjectType {
140
- return instanceOf ( type , GraphQLInputObjectType ) ;
139
+ return type instanceof GraphQLInputObjectType ;
141
140
}
142
141
143
142
export function assertInputObjectType ( type : unknown ) : GraphQLInputObjectType {
@@ -157,7 +156,7 @@ export function isListType(
157
156
) : type is GraphQLList < GraphQLOutputType > ;
158
157
export function isListType ( type : unknown ) : type is GraphQLList < GraphQLType > ;
159
158
export function isListType ( type : unknown ) : type is GraphQLList < GraphQLType > {
160
- return instanceOf ( type , GraphQLList ) ;
159
+ return type instanceof GraphQLList ;
161
160
}
162
161
163
162
export function assertListType ( type : unknown ) : GraphQLList < GraphQLType > {
@@ -179,7 +178,7 @@ export function isNonNullType(
179
178
export function isNonNullType (
180
179
type : unknown ,
181
180
) : type is GraphQLNonNull < GraphQLNullableType > {
182
- return instanceOf ( type , GraphQLNonNull ) ;
181
+ return type instanceof GraphQLNonNull ;
183
182
}
184
183
185
184
export function assertNonNullType (
0 commit comments