UNPKG

991 BTypeScriptView Raw
1import { GraphQLSchema } from 'graphql';
2import { SubschemaConfig, Transform, MergedTypeConfig, CreateProxyingResolverFn, BatchingOptions } from './types';
3import { Executor } from '@graphql-tools/utils';
4export declare function isSubschema(value: any): value is Subschema;
5interface ISubschema<K = any, V = any, C = K, TContext = Record<string, any>> extends SubschemaConfig<K, V, C, TContext> {
6 transformedSchema: GraphQLSchema;
7}
8export declare class Subschema<K = any, V = any, C = K, TContext = Record<string, any>> implements ISubschema<K, V, C, TContext> {
9 schema: GraphQLSchema;
10 executor?: Executor<TContext>;
11 batch?: boolean;
12 batchingOptions?: BatchingOptions<K, V, C>;
13 createProxyingResolver?: CreateProxyingResolverFn<TContext>;
14 transforms: Array<Transform<any, TContext>>;
15 transformedSchema: GraphQLSchema;
16 merge?: Record<string, MergedTypeConfig<any, any, TContext>>;
17 constructor(config: SubschemaConfig<K, V, C, TContext>);
18}
19export {};