import { GraphQLOutputType , GraphQLList , GraphQLNonNull , GraphQLScalarType , GraphQLObjectType , GraphQLInterfaceType , GraphQLUnionType , GraphQLEnumType , } from 'graphql' ; export type GraphQLNamedOutputType = GraphQLScalarType | GraphQLObjectType | GraphQLInterfaceType | GraphQLUnionType | GraphQLEnumType ; param type export function getNamedOutputType ( type ) { if ( type instanceof GraphQLList ) { return getNamedOutputType ( type . ofType ) ; } else if ( type instanceof GraphQLNonNull ) { return getNamedOutputType ( type . ofType ) ; } return type ; }