UNPKG

graphql-mocks

Version:
12 lines (9 loc) 323 B
import { isListType, isNonNullType } from 'graphql'; /** * Checks if a type is a list type or a wrapped list type (ie: wrapped with non-null) */ function hasListType(type) { return isListType(type) || isNonNullType(type) && isListType(type.ofType); } export { hasListType }; //# sourceMappingURL=has-list-type.js.map