UNPKG

@graphql-mesh/transform-hoist-field

Version:
14 lines (13 loc) 1.02 kB
import type { GraphQLSchema } from 'graphql'; import type { MeshTransform, MeshTransformOptions, YamlConfig } from '@graphql-mesh/types'; import type { DelegationContext, SubschemaConfig } from '@graphql-tools/delegate'; import type { ExecutionRequest, ExecutionResult } from '@graphql-tools/utils'; export default class MeshHoistField implements MeshTransform { noWrap: boolean; private transforms; constructor({ config }: MeshTransformOptions<YamlConfig.HoistFieldTransformConfig[]>); private getPathConfigItem; transformSchema(originalWrappingSchema: GraphQLSchema, subschemaConfig: SubschemaConfig, transformedSchema?: GraphQLSchema): GraphQLSchema; transformRequest(originalRequest: ExecutionRequest, delegationContext: DelegationContext, transformationContext: Record<string, any>): ExecutionRequest<any, any, any, Record<string, any>, any>; transformResult(originalResult: ExecutionResult, delegationContext: DelegationContext, transformationContext: any): ExecutionResult<any, any>; }