File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change 22 EnumTypeComposer ,
33 SchemaComposer ,
44 ObjectTypeComposer ,
5+ ComposeOutputType ,
56} from 'graphql-compose' ;
67import { GraphQLScalarType } from 'graphql-compose/lib/graphql' ;
78import { Model , Schema } from 'mongoose' ;
@@ -12,12 +13,6 @@ type MongooseFieldT = any;
1213type MongooseFieldMapT = { [ fieldName : string ] : MongooseFieldT } ;
1314type ComposeScalarType = string | GraphQLScalarType ;
1415
15- type ComposeOutputType =
16- | ObjectTypeComposer < any >
17- | ComposeScalarType
18- | EnumTypeComposer
19- | [ ObjectTypeComposer < any > | ComposeScalarType | EnumTypeComposer ] ;
20-
2116export type MongoosePseudoModelT = {
2217 schema : Schema ;
2318} ;
@@ -56,7 +51,7 @@ export function convertFieldToGraphQL(
5651 field : MongooseFieldT ,
5752 prefix : string | undefined ,
5853 schemaComposer : SchemaComposer < any > ,
59- ) : ComposeOutputType ;
54+ ) : ComposeOutputType < any , any > ;
6055
6156export function deriveComplexType (
6257 field : MongooseFieldT ,
@@ -68,7 +63,7 @@ export function arrayToGraphQL(
6863 field : MongooseFieldT ,
6964 prefix : string | undefined ,
7065 schemaComposer : SchemaComposer < any > ,
71- ) : ComposeOutputType ;
66+ ) : ComposeOutputType < any , any > ;
7267
7368export function embeddedToGraphQL (
7469 field : MongooseFieldT ,
You can’t perform that action at this time.
0 commit comments