Docs
API Reference
Classes
MapFields

Class: MapFields<TContext>

wrap/src.MapFields

Type parameters

Name
TContext

Implements

  • Transform<MapFieldsTransformationContext, TContext>

Table of contents

Constructors

Methods

Constructors

constructor

new MapFields<TContext>(fieldNodeTransformerMap, objectValueTransformerMap?, errorsTransformer?)

Type parameters

Name
TContext

Parameters

NameType
fieldNodeTransformerMapFieldNodeMappers
objectValueTransformerMap?ObjectValueTransformerMap
errorsTransformer?ErrorsTransformer

Defined in

packages/wrap/src/transforms/MapFields.ts:19 (opens in a new tab)

Methods

transformRequest

transformRequest(originalRequest, delegationContext, transformationContext): ExecutionRequest<Record<string, any>, any, any, Record<string, any>>

Parameters

NameType
originalRequestExecutionRequest<Record<string, any>, any, any, Record<string, any>>
delegationContextDelegationContext<TContext>
transformationContextMapFieldsTransformationContext

Returns

ExecutionRequest<Record<string, any>, any, any, Record<string, any>>

Implementation of

Transform.transformRequest

Defined in

packages/wrap/src/transforms/MapFields.ts:88 (opens in a new tab)


transformResult

transformResult(originalResult, delegationContext, transformationContext): ExecutionResult<any, any>

Parameters

NameType
originalResultExecutionResult<any, any>
delegationContextDelegationContext<TContext>
transformationContextMapFieldsTransformationContext

Returns

ExecutionResult<any, any>

Implementation of

Transform.transformResult

Defined in

packages/wrap/src/transforms/MapFields.ts:96 (opens in a new tab)


transformSchema

transformSchema(originalWrappingSchema, subschemaConfig): GraphQLSchema

Parameters

NameType
originalWrappingSchemaGraphQLSchema
subschemaConfigSubschemaConfig<any, any, any, TContext>

Returns

GraphQLSchema

Implementation of

Transform.transformSchema

Defined in

packages/wrap/src/transforms/MapFields.ts:39 (opens in a new tab)