UNPKG

@pallad/graphql-command-bus

Version:
18 lines (17 loc) 648 B
import { GraphQLInputObjectType, GraphQLObjectType } from 'graphql'; import { ObjectTypeComposer } from 'graphql-compose'; export declare namespace QueryHelper { function createQueryType(options: QueryOptions): GraphQLInputObjectType; function createQueryResultType(type: ObjectTypeComposer<any>, pagination?: PaginationOptions): GraphQLObjectType<any, any>; type PaginationOptions = { byNode: true; } | { byOffset: true; }; interface QueryOptions { filters: GraphQLInputObjectType; sortableFields?: string[]; singleSortable?: boolean; pagination?: PaginationOptions; } }