@graphql-codegen/visitor-plugin-common

  • Version 7.0.4
  • Published
  • 676 kB
  • 10 dependencies
  • MIT license

Install

npm i @graphql-codegen/visitor-plugin-common
yarn add @graphql-codegen/visitor-plugin-common
pnpm add @graphql-codegen/visitor-plugin-common

Overview

Overview not available.

Index

Variables

Functions

Classes

Interfaces

Enums

Type Aliases

Variables

variable DEFAULT_AVOID_OPTIONALS

const DEFAULT_AVOID_OPTIONALS: Required<AvoidOptionalsConfig>;

    variable DEFAULT_DECLARATION_KINDS

    const DEFAULT_DECLARATION_KINDS: DeclarationKindConfig;

      variable DEFAULT_INPUT_SCALARS

      const DEFAULT_INPUT_SCALARS: NormalizedScalarsMap;

        variable DEFAULT_SCALARS

        const DEFAULT_SCALARS: NormalizedScalarsMap;

          variable OMIT_TYPE

          const OMIT_TYPE: string;

            variable REQUIRE_FIELDS_TYPE

            const REQUIRE_FIELDS_TYPE: string;

              Functions

              function block

              block: (array: any) => string;

                function breakLine

                breakLine: (str: string) => string;

                  function buildEnumValuesBlock

                  buildEnumValuesBlock: ({
                  typeName,
                  values,
                  schema,
                  naming,
                  ignoreEnumValuesFromSchema,
                  declarationBlockConfig,
                  enumValues,
                  }: Pick<
                  ConvertSchemaEnumToDeclarationBlockString,
                  | 'schema'
                  | 'naming'
                  | 'ignoreEnumValuesFromSchema'
                  | 'declarationBlockConfig'
                  | 'enumValues'
                  > & { typeName: string; values: ReadonlyArray<EnumValueDefinitionNode> }) => string;

                    function buildMapperImport

                    buildMapperImport: (
                    source: string,
                    types: { identifier: string; asDefault?: boolean }[],
                    useTypeImports: boolean
                    ) => string | null;

                      function buildScalars

                      buildScalars: (
                      schema: GraphQLSchema | undefined,
                      scalarsMapping: ScalarsMap,
                      defaultScalarsMapping?: NormalizedScalarsMap,
                      defaultScalarType?: string | null
                      ) => ParsedScalarsMap;

                        function buildScalarsFromConfig

                        buildScalarsFromConfig: (
                        schema: GraphQLSchema | undefined,
                        config: RawConfig,
                        defaultScalarsMapping?: NormalizedScalarsMap,
                        defaultScalarType?: string
                        ) => ParsedScalarsMap;

                          function buildTypeImport

                          buildTypeImport: ({
                          identifier,
                          source,
                          useTypeImports,
                          asDefault,
                          }: {
                          identifier: string;
                          source: string;
                          useTypeImports: boolean;
                          asDefault?: boolean;
                          }) => string;

                            function clearExtension

                            clearExtension: (path: string) => string;

                              function convertFactory

                              convertFactory: (config: { namingConvention?: NamingConvention }) => ConvertFn;

                                function convertName

                                convertName: ({
                                convert,
                                options,
                                }: {
                                options: {
                                typesPrefix: string;
                                useTypesPrefix?: boolean;
                                typesSuffix: string;
                                useTypesSuffix?: boolean;
                                };
                                convert: () => string;
                                }) => string;

                                  function convertSchemaEnumToDeclarationBlockString

                                  convertSchemaEnumToDeclarationBlockString: ({
                                  schema,
                                  node,
                                  enumName,
                                  enumValues,
                                  futureProofEnums,
                                  ignoreEnumValuesFromSchema,
                                  outputType,
                                  declarationBlockConfig,
                                  naming,
                                  }: ConvertSchemaEnumToDeclarationBlockString) => string;

                                    function fixLocalFilePath

                                    fixLocalFilePath: (path: string) => string;

                                      function flatten

                                      flatten: <T>(array: Array<Array<T>>) => Array<T>;

                                        function generateFragmentImportStatement

                                        generateFragmentImportStatement: (
                                        statement: ImportDeclaration<FragmentImport>,
                                        kind: 'type' | 'document' | 'both'
                                        ) => string;

                                          function generateImportStatement

                                          generateImportStatement: (statement: ImportDeclaration) => string;

                                            function getBaseTypeNode

                                            getBaseTypeNode: (typeNode: TypeNode) => NamedTypeNode;

                                              function getConfigValue

                                              getConfigValue: <T = any>(value: T, defaultValue: T) => T;

                                                function getEnumsImports

                                                getEnumsImports: ({
                                                enumValues,
                                                useTypeImports,
                                                }: {
                                                enumValues: ParsedEnumValuesMap;
                                                useTypeImports: boolean;
                                                }) => string[];

                                                  function getFieldNames

                                                  getFieldNames: ({
                                                  selections,
                                                  fieldNames,
                                                  parentName,
                                                  loadedFragments,
                                                  }: {
                                                  selections: readonly SelectionNode[];
                                                  fieldNames?: Set<string>;
                                                  parentName?: string;
                                                  loadedFragments: LoadedFragment[];
                                                  }) => Set<string>;

                                                    function getFieldNodeNameValue

                                                    getFieldNodeNameValue: (node: FieldNode) => string;

                                                      function getNodeComment

                                                      getNodeComment: (
                                                      node: FieldDefinitionNode | EnumValueDefinitionNode | InputValueDefinitionNode
                                                      ) => string;

                                                        function getPossibleTypes

                                                        getPossibleTypes: (
                                                        schema: GraphQLSchema,
                                                        type: GraphQLNamedType
                                                        ) => GraphQLObjectType[];

                                                          function groupBy

                                                          groupBy: <T>(
                                                          array: Array<T>,
                                                          key: (item: T) => string | number
                                                          ) => { [key: string]: T[] };

                                                            function hasConditionalDirectives

                                                            hasConditionalDirectives: (directives?: readonly DirectiveNode[]) => boolean;
                                                            • Check if any of the directives are conditional i.e. @skip and @include

                                                            function hasIncrementalDeliveryDirectives

                                                            hasIncrementalDeliveryDirectives: (
                                                            directives?: readonly DirectiveNode[]
                                                            ) => boolean;
                                                            • Check if any of the directives are incremental i.e. @defer

                                                            function indent

                                                            indent: (str: string, count?: number) => string;

                                                              function indentMultiline

                                                              indentMultiline: (str: string, count?: number) => string;

                                                                function isExternalMapper

                                                                isExternalMapper: (value: string) => boolean;

                                                                  function isExternalMapperType

                                                                  isExternalMapperType: (m: ParsedMapper) => m is ExternalParsedMapper;

                                                                    function isNativeNamedType

                                                                    isNativeNamedType: (namedType: GraphQLNamedType) => boolean;

                                                                      function isOneOfInputObjectType

                                                                      isOneOfInputObjectType: (
                                                                      namedType: GraphQLNamedType | null | undefined
                                                                      ) => namedType is GraphQLInputObjectType;

                                                                        function mergeSelectionSets

                                                                        mergeSelectionSets: (
                                                                        selectionSet1: SelectionSetNode,
                                                                        selectionSet2: SelectionSetNode
                                                                        ) => SelectionSetNode;
                                                                        • merge selection sets into a new selection set without mutating the inputs.

                                                                        function normalizeAvoidOptionals

                                                                        normalizeAvoidOptionals: (
                                                                        avoidOptionals?: boolean | AvoidOptionalsConfig
                                                                        ) => NormalizedAvoidOptionalsConfig;

                                                                          function normalizeDeclarationKind

                                                                          normalizeDeclarationKind: (
                                                                          declarationKind?: DeclarationKind | DeclarationKindConfig
                                                                          ) => DeclarationKindConfig;

                                                                            function normalizeOperationAvoidOptionals

                                                                            normalizeOperationAvoidOptionals: (
                                                                            avoidOptionals: boolean | OperationAvoidOptionalsConfig
                                                                            ) => NormalizedOperationAvoidOptionalsConfig;

                                                                              function normalizeOperationDeclarationKind

                                                                              normalizeOperationDeclarationKind: (
                                                                              declarationKind: OperationDeclarationKind | OperationDeclarationKindConfig
                                                                              ) => NormalizedOperationDeclarationKindConfig;

                                                                                function optimizeOperations

                                                                                optimizeOperations: (
                                                                                schema: GraphQLSchema,
                                                                                documents: Types.DocumentFile[],
                                                                                options?: { includeFragments: boolean }
                                                                                ) => Types.DocumentFile[];

                                                                                  function parseEnumValues

                                                                                  parseEnumValues: ({
                                                                                  schema,
                                                                                  mapOrStr,
                                                                                  ignoreEnumValuesFromSchema,
                                                                                  naming,
                                                                                  }: {
                                                                                  schema: GraphQLSchema;
                                                                                  mapOrStr: EnumValuesMap;
                                                                                  ignoreEnumValuesFromSchema?: boolean;
                                                                                  naming: {
                                                                                  convert: ConvertFn;
                                                                                  options: {
                                                                                  typesPrefix: string;
                                                                                  typesSuffix: string;
                                                                                  useTypesPrefix?: boolean;
                                                                                  useTypesSuffix?: boolean;
                                                                                  };
                                                                                  };
                                                                                  }) => ParsedEnumValuesMap;

                                                                                    function parseMapper

                                                                                    parseMapper: (
                                                                                    mapper: string,
                                                                                    gqlTypeName?: string | null,
                                                                                    suffix?: string
                                                                                    ) => ParsedMapper;

                                                                                      function printTypeScriptMaybeType

                                                                                      printTypeScriptMaybeType: ({
                                                                                      type,
                                                                                      pattern,
                                                                                      }: {
                                                                                      type: string;
                                                                                      pattern: string;
                                                                                      }) => string;
                                                                                      • Utility function to print a TypeScript type that is Maybe. We need this since some TypeScript types have special handling. e.g. unknown | null | undefined is treated as unknown

                                                                                        Note: we currently have two types of handling nullable: Maybe<T> or T | null | undefined This function only handles the latter case at the moment, but could be extended if needed.

                                                                                        Parameter params

                                                                                        Parameter

                                                                                        {string} params.type - The TypeScript type e.g. any, unknown, string, Something

                                                                                        Parameter

                                                                                        {string} params.pattern - The pattern of the Maybe type. This is usually T | null | undefined or T | null

                                                                                        Returns

                                                                                        {string} The TypeScript type as string

                                                                                      function quoteIfNeeded

                                                                                      quoteIfNeeded: (array: string[], joinWith?: string) => string;

                                                                                        function removeDescription

                                                                                        removeDescription: <T extends { description?: StringValueNode }>(
                                                                                        nodes: readonly T[]
                                                                                        ) => (T & { description: any })[];

                                                                                          function resolveImportSource

                                                                                          resolveImportSource: <T>(source: string | ImportSource<T>) => ImportSource<T>;

                                                                                            function resolveRelativeImport

                                                                                            resolveRelativeImport: (from: string, to: string) => string;

                                                                                              function separateSelectionSet

                                                                                              separateSelectionSet: (selections: ReadonlyArray<SelectionNode>) => {
                                                                                              fields: FieldNode[];
                                                                                              spreads: FragmentSpreadNode[];
                                                                                              inlines: InlineFragmentNode[];
                                                                                              };

                                                                                                function stripMapperTypeInterpolation

                                                                                                stripMapperTypeInterpolation: (identifier: string) => string;

                                                                                                  function transformComment

                                                                                                  transformComment: (
                                                                                                  comment: string | StringValueNode,
                                                                                                  indentLevel?: number,
                                                                                                  disabled?: boolean
                                                                                                  ) => string;

                                                                                                    function transformDirectiveArgumentAndInputFieldMappings

                                                                                                    transformDirectiveArgumentAndInputFieldMappings: (
                                                                                                    rawDirectiveArgumentAndInputFieldMappings: DirectiveArgumentAndInputFieldMappings,
                                                                                                    directiveArgumentAndInputFieldMappingTypeSuffix?: string
                                                                                                    ) => ParsedDirectiveArgumentAndInputFieldMappings;

                                                                                                      function transformMappers

                                                                                                      transformMappers: (
                                                                                                      rawMappers: RawResolversConfig['mappers'],
                                                                                                      mapperTypeSuffix?: string
                                                                                                      ) => ParsedResolversConfig['mappers'];

                                                                                                        function unique

                                                                                                        unique: <T>(array: Array<T>, key?: (item: T) => string | number) => Array<T>;

                                                                                                          function wrapTypeNodeWithModifiers

                                                                                                          wrapTypeNodeWithModifiers: (baseType: string, typeNode: TypeNode) => string;

                                                                                                            function wrapTypeWithModifiers

                                                                                                            wrapTypeWithModifiers: (
                                                                                                            baseType: string,
                                                                                                            type: GraphQLOutputType | GraphQLNamedType,
                                                                                                            options: WrapModifiersOptions
                                                                                                            ) => string;

                                                                                                              function wrapWithSingleQuotes

                                                                                                              wrapWithSingleQuotes: (
                                                                                                              value: string | number | NameNode,
                                                                                                              skipNumericCheck?: boolean
                                                                                                              ) => string;

                                                                                                                Classes

                                                                                                                class BaseDocumentsVisitor

                                                                                                                class BaseDocumentsVisitor<
                                                                                                                TRawConfig extends RawDocumentsConfig = RawDocumentsConfig,
                                                                                                                TPluginConfig extends ParsedDocumentsConfig = ParsedDocumentsConfig
                                                                                                                > extends BaseVisitor<TRawConfig, TPluginConfig> {}

                                                                                                                  constructor

                                                                                                                  constructor(
                                                                                                                  rawConfig: RawDocumentsConfig,
                                                                                                                  additionalConfig: ParsedDocumentsConfig,
                                                                                                                  _schema: GraphQLSchema,
                                                                                                                  defaultScalars?: NormalizedScalarsMap
                                                                                                                  );

                                                                                                                    property schema

                                                                                                                    readonly schema: GraphQLSchema;

                                                                                                                      method applyVariablesWrapper

                                                                                                                      protected applyVariablesWrapper: (
                                                                                                                      variablesBlock: string,
                                                                                                                      _operationType?: string
                                                                                                                      ) => string;

                                                                                                                        method FragmentDefinition

                                                                                                                        FragmentDefinition: (node: FragmentDefinitionNode) => string;

                                                                                                                          method getGlobalDeclarations

                                                                                                                          getGlobalDeclarations: (noExport?: boolean) => string[];

                                                                                                                            method OperationDefinition

                                                                                                                            OperationDefinition: (node: OperationDefinitionNode) => string | null;

                                                                                                                              method setDeclarationBlockConfig

                                                                                                                              setDeclarationBlockConfig: (config: DeclarationBlockConfig) => void;

                                                                                                                                method setSelectionSetHandler

                                                                                                                                setSelectionSetHandler: (handler: SelectionSetToObject) => void;

                                                                                                                                  method setVariablesTransformer

                                                                                                                                  setVariablesTransformer: (
                                                                                                                                  variablesTransfomer: OperationVariablesToObject
                                                                                                                                  ) => void;

                                                                                                                                    class BaseResolversVisitor

                                                                                                                                    class BaseResolversVisitor<
                                                                                                                                    TRawConfig extends RawResolversConfig = RawResolversConfig,
                                                                                                                                    TPluginConfig extends ParsedResolversConfig = ParsedResolversConfig
                                                                                                                                    > extends BaseVisitor<TRawConfig, TPluginConfig> {}

                                                                                                                                      constructor

                                                                                                                                      constructor(
                                                                                                                                      rawConfig: RawResolversConfig,
                                                                                                                                      additionalConfig: ParsedResolversConfig,
                                                                                                                                      _schema: GraphQLSchema,
                                                                                                                                      defaultScalars?: NormalizedScalarsMap,
                                                                                                                                      federationMeta?: FederationMeta
                                                                                                                                      );

                                                                                                                                        property defaultMapperType

                                                                                                                                        readonly defaultMapperType: string;

                                                                                                                                          property globalDeclarations

                                                                                                                                          readonly globalDeclarations: string[];

                                                                                                                                            property mappersImports

                                                                                                                                            readonly mappersImports: string[];

                                                                                                                                              property schema

                                                                                                                                              readonly schema: GraphQLSchema;

                                                                                                                                                property unusedMappers

                                                                                                                                                readonly unusedMappers: string[];

                                                                                                                                                  method applyMaybe

                                                                                                                                                  protected applyMaybe: (str: string) => string;

                                                                                                                                                    method applyOptionalFields

                                                                                                                                                    protected applyOptionalFields: (
                                                                                                                                                    argsType: string,
                                                                                                                                                    _fields: readonly InputValueDefinitionNode[]
                                                                                                                                                    ) => string;

                                                                                                                                                      method applyRequireFields

                                                                                                                                                      protected applyRequireFields: (
                                                                                                                                                      argsType: string,
                                                                                                                                                      fields: InputValueDefinitionNode[]
                                                                                                                                                      ) => string;

                                                                                                                                                        method applyResolverTypeWrapper

                                                                                                                                                        protected applyResolverTypeWrapper: (str: string) => string;

                                                                                                                                                          method buildEnumResolverContentBlock

                                                                                                                                                          protected buildEnumResolverContentBlock: (
                                                                                                                                                          _node: EnumTypeDefinitionNode,
                                                                                                                                                          _mappedEnumType: string
                                                                                                                                                          ) => string;

                                                                                                                                                            method buildEnumResolversExplicitMappedValues

                                                                                                                                                            protected buildEnumResolversExplicitMappedValues: (
                                                                                                                                                            _node: EnumTypeDefinitionNode,
                                                                                                                                                            _valuesMapping: { [valueName: string]: string | number }
                                                                                                                                                            ) => string;

                                                                                                                                                              method buildFederationReferenceTypes

                                                                                                                                                              buildFederationReferenceTypes: () => string;

                                                                                                                                                                method buildFederationTypes

                                                                                                                                                                buildFederationTypes: () => string;

                                                                                                                                                                  method buildResolversInterfaceTypes

                                                                                                                                                                  buildResolversInterfaceTypes: () => string;

                                                                                                                                                                    method buildResolversParentTypes

                                                                                                                                                                    buildResolversParentTypes: () => string;

                                                                                                                                                                      method buildResolversTypes

                                                                                                                                                                      buildResolversTypes: () => string;

                                                                                                                                                                        method buildResolversUnionTypes

                                                                                                                                                                        buildResolversUnionTypes: () => string;

                                                                                                                                                                          method clearMaybe

                                                                                                                                                                          protected clearMaybe: (str: string) => string;

                                                                                                                                                                            method clearResolverTypeWrapper

                                                                                                                                                                            protected clearResolverTypeWrapper: (str: string) => string;

                                                                                                                                                                              method convertName

                                                                                                                                                                              convertName: (
                                                                                                                                                                              node: ASTNode | string,
                                                                                                                                                                              options?: BaseVisitorConvertOptions & ConvertOptions,
                                                                                                                                                                              applyNamespacedImport?: boolean
                                                                                                                                                                              ) => string;

                                                                                                                                                                                method createDirectivedContextType

                                                                                                                                                                                protected createDirectivedContextType: () => FieldContextTypeMap;

                                                                                                                                                                                  method createFieldContextTypeMap

                                                                                                                                                                                  protected createFieldContextTypeMap: () => FieldContextTypeMap;

                                                                                                                                                                                    method createResolversFields

                                                                                                                                                                                    protected createResolversFields: ({
                                                                                                                                                                                    applyWrapper,
                                                                                                                                                                                    clearWrapper,
                                                                                                                                                                                    getTypeToUse,
                                                                                                                                                                                    currentType,
                                                                                                                                                                                    shouldInclude,
                                                                                                                                                                                    onNotMappedObjectType,
                                                                                                                                                                                    }: {
                                                                                                                                                                                    applyWrapper: (str: string) => string;
                                                                                                                                                                                    clearWrapper: (str: string) => string;
                                                                                                                                                                                    getTypeToUse: (str: string) => string;
                                                                                                                                                                                    currentType: 'ResolversTypes' | 'ResolversParentTypes';
                                                                                                                                                                                    shouldInclude?: (type: GraphQLNamedType) => boolean;
                                                                                                                                                                                    onNotMappedObjectType: (params: {
                                                                                                                                                                                    initialType: string;
                                                                                                                                                                                    typeName: string;
                                                                                                                                                                                    }) => string;
                                                                                                                                                                                    }) => ResolverTypes;

                                                                                                                                                                                      method createResolversInterfaceTypes

                                                                                                                                                                                      protected createResolversInterfaceTypes: () => Record<string, string>;

                                                                                                                                                                                        method createResolversUnionTypes

                                                                                                                                                                                        protected createResolversUnionTypes: () => Record<string, string>;

                                                                                                                                                                                          method DirectiveDefinition

                                                                                                                                                                                          DirectiveDefinition: (
                                                                                                                                                                                          node: DirectiveDefinitionNode,
                                                                                                                                                                                          key: string | number,
                                                                                                                                                                                          parent: any
                                                                                                                                                                                          ) => string;

                                                                                                                                                                                            method EnumTypeDefinition

                                                                                                                                                                                            EnumTypeDefinition: (node: EnumTypeDefinitionNode) => string;

                                                                                                                                                                                              method FieldDefinition

                                                                                                                                                                                              FieldDefinition: (
                                                                                                                                                                                              node: FieldDefinitionNode,
                                                                                                                                                                                              key: string | number,
                                                                                                                                                                                              parent: any
                                                                                                                                                                                              ) => FieldDefinitionResult;

                                                                                                                                                                                                method formatRootResolver

                                                                                                                                                                                                protected formatRootResolver: (
                                                                                                                                                                                                schemaTypeName: string,
                                                                                                                                                                                                resolverType: string,
                                                                                                                                                                                                declarationKind: DeclarationKind
                                                                                                                                                                                                ) => string;

                                                                                                                                                                                                  method getAbstractMembersType

                                                                                                                                                                                                  getAbstractMembersType: ({
                                                                                                                                                                                                  typeName,
                                                                                                                                                                                                  memberTypes,
                                                                                                                                                                                                  isTypenameNonOptional,
                                                                                                                                                                                                  }: {
                                                                                                                                                                                                  typeName: string;
                                                                                                                                                                                                  memberTypes: readonly GraphQLObjectType[] | GraphQLObjectType[];
                                                                                                                                                                                                  isTypenameNonOptional: boolean;
                                                                                                                                                                                                  }) => string;
                                                                                                                                                                                                  • Function to generate the types of Abstract Type Members i.e. Union Members or Interface Implementing Types

                                                                                                                                                                                                  method getAllDirectiveResolvers

                                                                                                                                                                                                  getAllDirectiveResolvers: () => string;

                                                                                                                                                                                                    method getParentTypeForSignature

                                                                                                                                                                                                    protected getParentTypeForSignature: (_node: FieldDefinitionNode) => string;

                                                                                                                                                                                                      method getParentTypeToUse

                                                                                                                                                                                                      protected getParentTypeToUse: (name: string) => string;

                                                                                                                                                                                                        method getResolverTypeWrapperSignature

                                                                                                                                                                                                        getResolverTypeWrapperSignature: () => string;

                                                                                                                                                                                                          method getRootResolver

                                                                                                                                                                                                          getRootResolver: () => RootResolver;

                                                                                                                                                                                                            method getTypeToUse

                                                                                                                                                                                                            protected getTypeToUse: (name: string) => string;

                                                                                                                                                                                                              method hasFederation

                                                                                                                                                                                                              hasFederation: () => boolean;

                                                                                                                                                                                                                method hasScalars

                                                                                                                                                                                                                hasScalars: () => boolean;

                                                                                                                                                                                                                  method InterfaceTypeDefinition

                                                                                                                                                                                                                  InterfaceTypeDefinition: (node: InterfaceTypeDefinitionNode) => string;

                                                                                                                                                                                                                    method isMapperImported

                                                                                                                                                                                                                    protected isMapperImported: (
                                                                                                                                                                                                                    groupedMappers: GroupedMappers,
                                                                                                                                                                                                                    identifier: string,
                                                                                                                                                                                                                    source: string
                                                                                                                                                                                                                    ) => boolean;

                                                                                                                                                                                                                      method ListType

                                                                                                                                                                                                                      ListType: (node: ListTypeNode) => string;

                                                                                                                                                                                                                        method markMapperAsUsed

                                                                                                                                                                                                                        protected markMapperAsUsed: (name: string) => void;

                                                                                                                                                                                                                          method NamedType

                                                                                                                                                                                                                          NamedType: (node: NamedTypeNode) => string;

                                                                                                                                                                                                                            method NonNullType

                                                                                                                                                                                                                            NonNullType: (node: NonNullTypeNode) => string;

                                                                                                                                                                                                                              method ObjectTypeDefinition

                                                                                                                                                                                                                              ObjectTypeDefinition: (node: ObjectTypeDefinitionNode) => string | null;

                                                                                                                                                                                                                                method replaceFieldsInType

                                                                                                                                                                                                                                protected replaceFieldsInType: (
                                                                                                                                                                                                                                typeName: string,
                                                                                                                                                                                                                                relevantFields: ReturnType<typeof this.getRelevantFieldsToOmit>
                                                                                                                                                                                                                                ) => string;

                                                                                                                                                                                                                                  method ScalarTypeDefinition

                                                                                                                                                                                                                                  ScalarTypeDefinition: (node: ScalarTypeDefinitionNode) => string;

                                                                                                                                                                                                                                    method SchemaDefinition

                                                                                                                                                                                                                                    SchemaDefinition: () => any;

                                                                                                                                                                                                                                      method SchemaExtension

                                                                                                                                                                                                                                      SchemaExtension: () => any;

                                                                                                                                                                                                                                        method setDeclarationBlockConfig

                                                                                                                                                                                                                                        setDeclarationBlockConfig: (config: DeclarationBlockConfig) => void;

                                                                                                                                                                                                                                          method setVariablesTransformer

                                                                                                                                                                                                                                          setVariablesTransformer: (
                                                                                                                                                                                                                                          variablesTransfomer: OperationVariablesToObject
                                                                                                                                                                                                                                          ) => void;

                                                                                                                                                                                                                                            method shouldMapType

                                                                                                                                                                                                                                            protected shouldMapType: (
                                                                                                                                                                                                                                            type: GraphQLNamedType,
                                                                                                                                                                                                                                            duringCheck?: string[]
                                                                                                                                                                                                                                            ) => boolean;

                                                                                                                                                                                                                                              method transformParentGenericType

                                                                                                                                                                                                                                              protected transformParentGenericType: (parentType: string) => string;

                                                                                                                                                                                                                                                method UnionTypeDefinition

                                                                                                                                                                                                                                                UnionTypeDefinition: (
                                                                                                                                                                                                                                                node: UnionTypeDefinitionNode,
                                                                                                                                                                                                                                                key: string | number,
                                                                                                                                                                                                                                                parent: any
                                                                                                                                                                                                                                                ) => string;

                                                                                                                                                                                                                                                  method wrapWithArray

                                                                                                                                                                                                                                                  protected wrapWithArray: (t: string) => string;

                                                                                                                                                                                                                                                    class BaseSelectionSetProcessor

                                                                                                                                                                                                                                                    class BaseSelectionSetProcessor<Config extends SelectionSetProcessorConfig> {}

                                                                                                                                                                                                                                                      constructor

                                                                                                                                                                                                                                                      constructor(config: SelectionSetProcessorConfig);

                                                                                                                                                                                                                                                        property config

                                                                                                                                                                                                                                                        config: SelectionSetProcessorConfig;

                                                                                                                                                                                                                                                          property typeCache

                                                                                                                                                                                                                                                          typeCache: Map<Location, Map<string, [string, string]>>;

                                                                                                                                                                                                                                                            method buildFieldsIntoObject

                                                                                                                                                                                                                                                            buildFieldsIntoObject: (allObjectsMerged: string[]) => string;

                                                                                                                                                                                                                                                              method buildSelectionSetFromStrings

                                                                                                                                                                                                                                                              buildSelectionSetFromStrings: (pieces: string[]) => string;

                                                                                                                                                                                                                                                                method transformAliasesPrimitiveFields

                                                                                                                                                                                                                                                                transformAliasesPrimitiveFields: (
                                                                                                                                                                                                                                                                _schemaType: GraphQLObjectType | GraphQLInterfaceType,
                                                                                                                                                                                                                                                                _fields: PrimitiveAliasedFields[],
                                                                                                                                                                                                                                                                _unsetTypes?: boolean
                                                                                                                                                                                                                                                                ) => (string | NameAndType)[];

                                                                                                                                                                                                                                                                  method transformLinkFields

                                                                                                                                                                                                                                                                  transformLinkFields: (
                                                                                                                                                                                                                                                                  _fields: LinkField[],
                                                                                                                                                                                                                                                                  _unsetTypes?: boolean
                                                                                                                                                                                                                                                                  ) => (string | NameAndType)[];

                                                                                                                                                                                                                                                                    method transformPrimitiveFields

                                                                                                                                                                                                                                                                    transformPrimitiveFields: (
                                                                                                                                                                                                                                                                    _schemaType: GraphQLObjectType | GraphQLInterfaceType,
                                                                                                                                                                                                                                                                    _fields: PrimitiveField[],
                                                                                                                                                                                                                                                                    _unsetTypes?: boolean
                                                                                                                                                                                                                                                                    ) => (string | NameAndType)[];

                                                                                                                                                                                                                                                                      method transformTypenameField

                                                                                                                                                                                                                                                                      transformTypenameField: (
                                                                                                                                                                                                                                                                      _type: string,
                                                                                                                                                                                                                                                                      _name: string
                                                                                                                                                                                                                                                                      ) => (string | NameAndType)[];

                                                                                                                                                                                                                                                                        class BaseTypesVisitor

                                                                                                                                                                                                                                                                        class BaseTypesVisitor<
                                                                                                                                                                                                                                                                        TRawConfig extends RawTypesConfig = RawTypesConfig,
                                                                                                                                                                                                                                                                        TPluginConfig extends ParsedTypesConfig = ParsedTypesConfig
                                                                                                                                                                                                                                                                        > extends BaseVisitor<TRawConfig, TPluginConfig> {}

                                                                                                                                                                                                                                                                          constructor

                                                                                                                                                                                                                                                                          constructor(
                                                                                                                                                                                                                                                                          _schema: GraphQLSchema,
                                                                                                                                                                                                                                                                          rawConfig: RawTypesConfig,
                                                                                                                                                                                                                                                                          additionalConfig: ParsedTypesConfig,
                                                                                                                                                                                                                                                                          defaultScalars?: NormalizedScalarsMap
                                                                                                                                                                                                                                                                          );

                                                                                                                                                                                                                                                                            property directiveArgumentAndInputFieldMappingsDefinition

                                                                                                                                                                                                                                                                            readonly directiveArgumentAndInputFieldMappingsDefinition: string;

                                                                                                                                                                                                                                                                              property scalarsDefinition

                                                                                                                                                                                                                                                                              readonly scalarsDefinition: string;

                                                                                                                                                                                                                                                                                method appendInterfacesAndFieldsToBlock

                                                                                                                                                                                                                                                                                appendInterfacesAndFieldsToBlock: (
                                                                                                                                                                                                                                                                                block: DeclarationBlock,
                                                                                                                                                                                                                                                                                interfaces: string[],
                                                                                                                                                                                                                                                                                fields: string[]
                                                                                                                                                                                                                                                                                ) => void;

                                                                                                                                                                                                                                                                                  method buildArgumentsBlock

                                                                                                                                                                                                                                                                                  protected buildArgumentsBlock: (
                                                                                                                                                                                                                                                                                  node: InterfaceTypeDefinitionNode | ObjectTypeDefinitionNode
                                                                                                                                                                                                                                                                                  ) => string;

                                                                                                                                                                                                                                                                                    method DirectiveDefinition

                                                                                                                                                                                                                                                                                    DirectiveDefinition: (_node: DirectiveDefinitionNode) => string;

                                                                                                                                                                                                                                                                                      method EnumTypeDefinition

                                                                                                                                                                                                                                                                                      EnumTypeDefinition: (node: EnumTypeDefinitionNode) => string;

                                                                                                                                                                                                                                                                                        method FieldDefinition

                                                                                                                                                                                                                                                                                        FieldDefinition: (node: FieldDefinitionNode) => string;

                                                                                                                                                                                                                                                                                          method getArgumentsObjectDeclarationBlock

                                                                                                                                                                                                                                                                                          getArgumentsObjectDeclarationBlock: (
                                                                                                                                                                                                                                                                                          node: InterfaceTypeDefinitionNode | ObjectTypeDefinitionNode,
                                                                                                                                                                                                                                                                                          name: string,
                                                                                                                                                                                                                                                                                          field: FieldDefinitionNode
                                                                                                                                                                                                                                                                                          ) => DeclarationBlock;

                                                                                                                                                                                                                                                                                            method getArgumentsObjectTypeDefinition

                                                                                                                                                                                                                                                                                            getArgumentsObjectTypeDefinition: (
                                                                                                                                                                                                                                                                                            node: InterfaceTypeDefinitionNode | ObjectTypeDefinitionNode,
                                                                                                                                                                                                                                                                                            name: string,
                                                                                                                                                                                                                                                                                            field: FieldDefinitionNode
                                                                                                                                                                                                                                                                                            ) => string;

                                                                                                                                                                                                                                                                                              method getDirectiveArgumentAndInputFieldMappingsImports

                                                                                                                                                                                                                                                                                              getDirectiveArgumentAndInputFieldMappingsImports: () => string[];

                                                                                                                                                                                                                                                                                                method getEntireFieldWrapperValue

                                                                                                                                                                                                                                                                                                getEntireFieldWrapperValue: () => string;

                                                                                                                                                                                                                                                                                                  method getEnumsImports

                                                                                                                                                                                                                                                                                                  getEnumsImports: () => string[];

                                                                                                                                                                                                                                                                                                    method getExportPrefix

                                                                                                                                                                                                                                                                                                    protected getExportPrefix: () => string;

                                                                                                                                                                                                                                                                                                      method getFieldWrapperValue

                                                                                                                                                                                                                                                                                                      getFieldWrapperValue: () => string;

                                                                                                                                                                                                                                                                                                        method getInputObjectDeclarationBlock

                                                                                                                                                                                                                                                                                                        getInputObjectDeclarationBlock: (
                                                                                                                                                                                                                                                                                                        node: InputObjectTypeDefinitionNode
                                                                                                                                                                                                                                                                                                        ) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                          method getInputObjectOneOfDeclarationBlock

                                                                                                                                                                                                                                                                                                          getInputObjectOneOfDeclarationBlock: (
                                                                                                                                                                                                                                                                                                          node: InputObjectTypeDefinitionNode
                                                                                                                                                                                                                                                                                                          ) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                            method getInterfaceTypeDeclarationBlock

                                                                                                                                                                                                                                                                                                            getInterfaceTypeDeclarationBlock: (
                                                                                                                                                                                                                                                                                                            node: InterfaceTypeDefinitionNode,
                                                                                                                                                                                                                                                                                                            _originalNode: InterfaceTypeDefinitionNode
                                                                                                                                                                                                                                                                                                            ) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                              method getObjectTypeDeclarationBlock

                                                                                                                                                                                                                                                                                                              getObjectTypeDeclarationBlock: (
                                                                                                                                                                                                                                                                                                              node: ObjectTypeDefinitionNode,
                                                                                                                                                                                                                                                                                                              originalNode: ObjectTypeDefinitionNode
                                                                                                                                                                                                                                                                                                              ) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                                method getScalarsImports

                                                                                                                                                                                                                                                                                                                getScalarsImports: () => string[];

                                                                                                                                                                                                                                                                                                                  method InputObjectTypeDefinition

                                                                                                                                                                                                                                                                                                                  InputObjectTypeDefinition: (node: InputObjectTypeDefinitionNode) => string;

                                                                                                                                                                                                                                                                                                                    method InputValueDefinition

                                                                                                                                                                                                                                                                                                                    InputValueDefinition: (node: InputValueDefinitionNode) => string;

                                                                                                                                                                                                                                                                                                                      method InterfaceTypeDefinition

                                                                                                                                                                                                                                                                                                                      InterfaceTypeDefinition: (
                                                                                                                                                                                                                                                                                                                      node: InterfaceTypeDefinitionNode,
                                                                                                                                                                                                                                                                                                                      key: number | string,
                                                                                                                                                                                                                                                                                                                      parent: any
                                                                                                                                                                                                                                                                                                                      ) => string;

                                                                                                                                                                                                                                                                                                                        method ListType

                                                                                                                                                                                                                                                                                                                        ListType: (
                                                                                                                                                                                                                                                                                                                        node: ListTypeNode,
                                                                                                                                                                                                                                                                                                                        _key: any,
                                                                                                                                                                                                                                                                                                                        _parent: any,
                                                                                                                                                                                                                                                                                                                        _path: any,
                                                                                                                                                                                                                                                                                                                        _ancestors: any
                                                                                                                                                                                                                                                                                                                        ) => string;

                                                                                                                                                                                                                                                                                                                          method makeValidEnumIdentifier

                                                                                                                                                                                                                                                                                                                          protected makeValidEnumIdentifier: (identifier: string) => string;

                                                                                                                                                                                                                                                                                                                            method mergeAllFields

                                                                                                                                                                                                                                                                                                                            protected mergeAllFields: (
                                                                                                                                                                                                                                                                                                                            allFields: string[],
                                                                                                                                                                                                                                                                                                                            _hasInterfaces: boolean
                                                                                                                                                                                                                                                                                                                            ) => string;

                                                                                                                                                                                                                                                                                                                              method mergeInterfaces

                                                                                                                                                                                                                                                                                                                              protected mergeInterfaces: (
                                                                                                                                                                                                                                                                                                                              interfaces: string[],
                                                                                                                                                                                                                                                                                                                              hasOtherFields: boolean
                                                                                                                                                                                                                                                                                                                              ) => string;

                                                                                                                                                                                                                                                                                                                                method NamedType

                                                                                                                                                                                                                                                                                                                                NamedType: (
                                                                                                                                                                                                                                                                                                                                node: NamedTypeNode,
                                                                                                                                                                                                                                                                                                                                key: any,
                                                                                                                                                                                                                                                                                                                                parent: any,
                                                                                                                                                                                                                                                                                                                                path: any,
                                                                                                                                                                                                                                                                                                                                ancestors: any
                                                                                                                                                                                                                                                                                                                                ) => string;

                                                                                                                                                                                                                                                                                                                                  method NonNullType

                                                                                                                                                                                                                                                                                                                                  NonNullType: (node: NonNullTypeNode) => string;

                                                                                                                                                                                                                                                                                                                                    method ObjectTypeDefinition

                                                                                                                                                                                                                                                                                                                                    ObjectTypeDefinition: (
                                                                                                                                                                                                                                                                                                                                    node: ObjectTypeDefinitionNode,
                                                                                                                                                                                                                                                                                                                                    key: number | string,
                                                                                                                                                                                                                                                                                                                                    parent: any
                                                                                                                                                                                                                                                                                                                                    ) => string;

                                                                                                                                                                                                                                                                                                                                      method ScalarTypeDefinition

                                                                                                                                                                                                                                                                                                                                      ScalarTypeDefinition: (_node: ScalarTypeDefinitionNode) => string;

                                                                                                                                                                                                                                                                                                                                        method SchemaDefinition

                                                                                                                                                                                                                                                                                                                                        SchemaDefinition: () => any;

                                                                                                                                                                                                                                                                                                                                          method SchemaExtension

                                                                                                                                                                                                                                                                                                                                          SchemaExtension: () => any;

                                                                                                                                                                                                                                                                                                                                            method setArgumentsTransformer

                                                                                                                                                                                                                                                                                                                                            setArgumentsTransformer: (
                                                                                                                                                                                                                                                                                                                                            argumentsTransfomer: OperationVariablesToObject
                                                                                                                                                                                                                                                                                                                                            ) => void;

                                                                                                                                                                                                                                                                                                                                              method setDeclarationBlockConfig

                                                                                                                                                                                                                                                                                                                                              setDeclarationBlockConfig: (config: DeclarationBlockConfig) => void;

                                                                                                                                                                                                                                                                                                                                                method UnionTypeDefinition

                                                                                                                                                                                                                                                                                                                                                UnionTypeDefinition: (
                                                                                                                                                                                                                                                                                                                                                node: UnionTypeDefinitionNode,
                                                                                                                                                                                                                                                                                                                                                key: string | number | undefined,
                                                                                                                                                                                                                                                                                                                                                parent: any
                                                                                                                                                                                                                                                                                                                                                ) => string;

                                                                                                                                                                                                                                                                                                                                                  method wrapWithListType

                                                                                                                                                                                                                                                                                                                                                  protected wrapWithListType: (str: string) => string;

                                                                                                                                                                                                                                                                                                                                                    class BaseVisitor

                                                                                                                                                                                                                                                                                                                                                    class BaseVisitor<
                                                                                                                                                                                                                                                                                                                                                    TRawConfig extends RawConfig = RawConfig,
                                                                                                                                                                                                                                                                                                                                                    TPluginConfig extends ParsedConfig = ParsedConfig
                                                                                                                                                                                                                                                                                                                                                    > {}

                                                                                                                                                                                                                                                                                                                                                      constructor

                                                                                                                                                                                                                                                                                                                                                      constructor(rawConfig: RawConfig, additionalConfig: Partial<TPluginConfig>);

                                                                                                                                                                                                                                                                                                                                                        property config

                                                                                                                                                                                                                                                                                                                                                        readonly config: ParsedConfig;

                                                                                                                                                                                                                                                                                                                                                          property scalars

                                                                                                                                                                                                                                                                                                                                                          readonly scalars: NormalizedScalarsMap;

                                                                                                                                                                                                                                                                                                                                                            method convertName

                                                                                                                                                                                                                                                                                                                                                            convertName: (
                                                                                                                                                                                                                                                                                                                                                            node: ASTNode | string,
                                                                                                                                                                                                                                                                                                                                                            options?: BaseVisitorConvertOptions & ConvertOptions
                                                                                                                                                                                                                                                                                                                                                            ) => string;

                                                                                                                                                                                                                                                                                                                                                              method getFragmentName

                                                                                                                                                                                                                                                                                                                                                              getFragmentName: (node: FragmentDefinitionNode | string) => string;

                                                                                                                                                                                                                                                                                                                                                                method getFragmentSuffix

                                                                                                                                                                                                                                                                                                                                                                getFragmentSuffix: (node: FragmentDefinitionNode | string) => string;

                                                                                                                                                                                                                                                                                                                                                                  method getFragmentVariableName

                                                                                                                                                                                                                                                                                                                                                                  getFragmentVariableName: (node: FragmentDefinitionNode | string) => string;

                                                                                                                                                                                                                                                                                                                                                                    method getOperationSuffix

                                                                                                                                                                                                                                                                                                                                                                    getOperationSuffix: (
                                                                                                                                                                                                                                                                                                                                                                    node: FragmentDefinitionNode | OperationDefinitionNode | string,
                                                                                                                                                                                                                                                                                                                                                                    operationType: string
                                                                                                                                                                                                                                                                                                                                                                    ) => string;

                                                                                                                                                                                                                                                                                                                                                                      method getPunctuation

                                                                                                                                                                                                                                                                                                                                                                      protected getPunctuation: (_declarationKind: DeclarationKind) => string;

                                                                                                                                                                                                                                                                                                                                                                        method getVisitorKindContextFromAncestors

                                                                                                                                                                                                                                                                                                                                                                        protected getVisitorKindContextFromAncestors: (ancestors: ASTNode[]) => string[];

                                                                                                                                                                                                                                                                                                                                                                          class ClientSideBaseVisitor

                                                                                                                                                                                                                                                                                                                                                                          class ClientSideBaseVisitor<
                                                                                                                                                                                                                                                                                                                                                                          TRawConfig extends RawClientSideBasePluginConfig = RawClientSideBasePluginConfig,
                                                                                                                                                                                                                                                                                                                                                                          TPluginConfig extends ClientSideBasePluginConfig = ClientSideBasePluginConfig
                                                                                                                                                                                                                                                                                                                                                                          > extends BaseVisitor<TRawConfig, TPluginConfig> {}

                                                                                                                                                                                                                                                                                                                                                                            constructor

                                                                                                                                                                                                                                                                                                                                                                            constructor(
                                                                                                                                                                                                                                                                                                                                                                            _schema: GraphQLSchema,
                                                                                                                                                                                                                                                                                                                                                                            fragments: {
                                                                                                                                                                                                                                                                                                                                                                            name: string;
                                                                                                                                                                                                                                                                                                                                                                            onType: string;
                                                                                                                                                                                                                                                                                                                                                                            node: FragmentDefinitionNode;
                                                                                                                                                                                                                                                                                                                                                                            isExternal: boolean;
                                                                                                                                                                                                                                                                                                                                                                            importFrom?: string;
                                                                                                                                                                                                                                                                                                                                                                            }[],
                                                                                                                                                                                                                                                                                                                                                                            rawConfig: RawClientSideBasePluginConfig,
                                                                                                                                                                                                                                                                                                                                                                            additionalConfig: Partial<TPluginConfig>,
                                                                                                                                                                                                                                                                                                                                                                            documents?: Types.DocumentFile[]
                                                                                                                                                                                                                                                                                                                                                                            );

                                                                                                                                                                                                                                                                                                                                                                              property fragments

                                                                                                                                                                                                                                                                                                                                                                              readonly fragments: string;

                                                                                                                                                                                                                                                                                                                                                                                method buildOperation

                                                                                                                                                                                                                                                                                                                                                                                protected buildOperation: (
                                                                                                                                                                                                                                                                                                                                                                                _node: OperationDefinitionNode,
                                                                                                                                                                                                                                                                                                                                                                                _documentVariableName: string,
                                                                                                                                                                                                                                                                                                                                                                                _operationType: string,
                                                                                                                                                                                                                                                                                                                                                                                _operationResultType: string,
                                                                                                                                                                                                                                                                                                                                                                                _operationVariablesTypes: string,
                                                                                                                                                                                                                                                                                                                                                                                _hasRequiredVariables: boolean
                                                                                                                                                                                                                                                                                                                                                                                ) => string;

                                                                                                                                                                                                                                                                                                                                                                                  method checkVariablesRequirements

                                                                                                                                                                                                                                                                                                                                                                                  protected checkVariablesRequirements: (node: OperationDefinitionNode) => boolean;
                                                                                                                                                                                                                                                                                                                                                                                  • Checks if the specific operation has variables that are non-null (required), and also doesn't have default. This is useful for deciding of variables should be optional or not.

                                                                                                                                                                                                                                                                                                                                                                                    Parameter node

                                                                                                                                                                                                                                                                                                                                                                                  method getDocumentNodeSignature

                                                                                                                                                                                                                                                                                                                                                                                  protected getDocumentNodeSignature: (
                                                                                                                                                                                                                                                                                                                                                                                  _resultType: string,
                                                                                                                                                                                                                                                                                                                                                                                  _variablesTypes: string,
                                                                                                                                                                                                                                                                                                                                                                                  _node: FragmentDefinitionNode | OperationDefinitionNode
                                                                                                                                                                                                                                                                                                                                                                                  ) => string;

                                                                                                                                                                                                                                                                                                                                                                                    method getImports

                                                                                                                                                                                                                                                                                                                                                                                    getImports: (options?: { excludeFragments?: boolean }) => string[];

                                                                                                                                                                                                                                                                                                                                                                                      method getOperationVariableName

                                                                                                                                                                                                                                                                                                                                                                                      getOperationVariableName: (node: OperationDefinitionNode) => string;

                                                                                                                                                                                                                                                                                                                                                                                        method OperationDefinition

                                                                                                                                                                                                                                                                                                                                                                                        OperationDefinition: (node: OperationDefinitionNode) => string;

                                                                                                                                                                                                                                                                                                                                                                                          class DeclarationBlock

                                                                                                                                                                                                                                                                                                                                                                                          class DeclarationBlock {}

                                                                                                                                                                                                                                                                                                                                                                                            constructor

                                                                                                                                                                                                                                                                                                                                                                                            constructor(_config: DeclarationBlockConfig);

                                                                                                                                                                                                                                                                                                                                                                                              property string

                                                                                                                                                                                                                                                                                                                                                                                              readonly string: string;

                                                                                                                                                                                                                                                                                                                                                                                                method asKind

                                                                                                                                                                                                                                                                                                                                                                                                asKind: (kind: string) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                                                                                                                  method export

                                                                                                                                                                                                                                                                                                                                                                                                  export: (exp?: boolean) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                                                                                                                    method withBlock

                                                                                                                                                                                                                                                                                                                                                                                                    withBlock: (block: string) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                                                                                                                      method withComment

                                                                                                                                                                                                                                                                                                                                                                                                      withComment: (
                                                                                                                                                                                                                                                                                                                                                                                                      comment: string | StringValueNode | null,
                                                                                                                                                                                                                                                                                                                                                                                                      disabled?: boolean
                                                                                                                                                                                                                                                                                                                                                                                                      ) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                                                                                                                        method withContent

                                                                                                                                                                                                                                                                                                                                                                                                        withContent: (content: string) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                                                                                                                          method withDecorator

                                                                                                                                                                                                                                                                                                                                                                                                          withDecorator: (decorator: string) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                                                                                                                            method withMethodCall

                                                                                                                                                                                                                                                                                                                                                                                                            withMethodCall: (
                                                                                                                                                                                                                                                                                                                                                                                                            methodName: string,
                                                                                                                                                                                                                                                                                                                                                                                                            ignoreBlockWrapper?: boolean
                                                                                                                                                                                                                                                                                                                                                                                                            ) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                                                                                                                              method withName

                                                                                                                                                                                                                                                                                                                                                                                                              withName: (
                                                                                                                                                                                                                                                                                                                                                                                                              name: string | NameNode,
                                                                                                                                                                                                                                                                                                                                                                                                              generics?: string | null
                                                                                                                                                                                                                                                                                                                                                                                                              ) => DeclarationBlock;

                                                                                                                                                                                                                                                                                                                                                                                                                class OperationVariablesToObject

                                                                                                                                                                                                                                                                                                                                                                                                                class OperationVariablesToObject {}

                                                                                                                                                                                                                                                                                                                                                                                                                  constructor

                                                                                                                                                                                                                                                                                                                                                                                                                  constructor(
                                                                                                                                                                                                                                                                                                                                                                                                                  _scalars: NormalizedScalarsMap,
                                                                                                                                                                                                                                                                                                                                                                                                                  _convertName: ConvertNameFn<BaseVisitorConvertOptions>,
                                                                                                                                                                                                                                                                                                                                                                                                                  _namespacedImportName?: string,
                                                                                                                                                                                                                                                                                                                                                                                                                  _enumNames?: string[],
                                                                                                                                                                                                                                                                                                                                                                                                                  _enumPrefix?: boolean,
                                                                                                                                                                                                                                                                                                                                                                                                                  _enumSuffix?: boolean,
                                                                                                                                                                                                                                                                                                                                                                                                                  _enumValues?: ParsedEnumValuesMap,
                                                                                                                                                                                                                                                                                                                                                                                                                  _applyCoercion?: boolean,
                                                                                                                                                                                                                                                                                                                                                                                                                  _directiveArgumentAndInputFieldMappings?: ParsedDirectiveArgumentAndInputFieldMappings
                                                                                                                                                                                                                                                                                                                                                                                                                  );

                                                                                                                                                                                                                                                                                                                                                                                                                    method formatFieldString

                                                                                                                                                                                                                                                                                                                                                                                                                    protected formatFieldString: (
                                                                                                                                                                                                                                                                                                                                                                                                                    fieldName: string,
                                                                                                                                                                                                                                                                                                                                                                                                                    _isNonNullType: boolean,
                                                                                                                                                                                                                                                                                                                                                                                                                    _hasDefaultValue: boolean
                                                                                                                                                                                                                                                                                                                                                                                                                    ) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                      method formatTypeString

                                                                                                                                                                                                                                                                                                                                                                                                                      protected formatTypeString: (
                                                                                                                                                                                                                                                                                                                                                                                                                      fieldType: string,
                                                                                                                                                                                                                                                                                                                                                                                                                      isNonNullType: boolean,
                                                                                                                                                                                                                                                                                                                                                                                                                      hasDefaultValue: boolean
                                                                                                                                                                                                                                                                                                                                                                                                                      ) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                        method getDirectiveMapping

                                                                                                                                                                                                                                                                                                                                                                                                                        protected getDirectiveMapping: (name: string) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                          method getDirectiveOverrideType

                                                                                                                                                                                                                                                                                                                                                                                                                          protected getDirectiveOverrideType: (
                                                                                                                                                                                                                                                                                                                                                                                                                          directives: ReadonlyArray<DirectiveNode>
                                                                                                                                                                                                                                                                                                                                                                                                                          ) => string | null;

                                                                                                                                                                                                                                                                                                                                                                                                                            method getName

                                                                                                                                                                                                                                                                                                                                                                                                                            getName: <TDefinitionType extends InterfaceOrVariable>(
                                                                                                                                                                                                                                                                                                                                                                                                                            node: TDefinitionType
                                                                                                                                                                                                                                                                                                                                                                                                                            ) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                              method getPunctuation

                                                                                                                                                                                                                                                                                                                                                                                                                              protected getPunctuation: () => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                method getScalar

                                                                                                                                                                                                                                                                                                                                                                                                                                protected getScalar: (name: string) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                  method transform

                                                                                                                                                                                                                                                                                                                                                                                                                                  transform: <TDefinitionType extends InterfaceOrVariable>(
                                                                                                                                                                                                                                                                                                                                                                                                                                  variablesNode: ReadonlyArray<TDefinitionType>
                                                                                                                                                                                                                                                                                                                                                                                                                                  ) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                    method transformVariable

                                                                                                                                                                                                                                                                                                                                                                                                                                    protected transformVariable: <TDefinitionType extends InterfaceOrVariable>(
                                                                                                                                                                                                                                                                                                                                                                                                                                    variable: TDefinitionType
                                                                                                                                                                                                                                                                                                                                                                                                                                    ) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                      method wrapAstTypeWithModifiers

                                                                                                                                                                                                                                                                                                                                                                                                                                      wrapAstTypeWithModifiers: (
                                                                                                                                                                                                                                                                                                                                                                                                                                      _baseType: string,
                                                                                                                                                                                                                                                                                                                                                                                                                                      _typeNode: TypeNode,
                                                                                                                                                                                                                                                                                                                                                                                                                                      _applyCoercion?: boolean
                                                                                                                                                                                                                                                                                                                                                                                                                                      ) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                        class PreResolveTypesProcessor

                                                                                                                                                                                                                                                                                                                                                                                                                                        class PreResolveTypesProcessor extends BaseSelectionSetProcessor<SelectionSetProcessorConfig> {}

                                                                                                                                                                                                                                                                                                                                                                                                                                          method transformAliasesPrimitiveFields

                                                                                                                                                                                                                                                                                                                                                                                                                                          transformAliasesPrimitiveFields: (
                                                                                                                                                                                                                                                                                                                                                                                                                                          schemaType: GraphQLObjectType | GraphQLInterfaceType,
                                                                                                                                                                                                                                                                                                                                                                                                                                          fields: PrimitiveAliasedFields[],
                                                                                                                                                                                                                                                                                                                                                                                                                                          unsetTypes?: boolean
                                                                                                                                                                                                                                                                                                                                                                                                                                          ) => (string | NameAndType)[];

                                                                                                                                                                                                                                                                                                                                                                                                                                            method transformLinkFields

                                                                                                                                                                                                                                                                                                                                                                                                                                            transformLinkFields: (
                                                                                                                                                                                                                                                                                                                                                                                                                                            fields: LinkField[],
                                                                                                                                                                                                                                                                                                                                                                                                                                            unsetTypes?: boolean
                                                                                                                                                                                                                                                                                                                                                                                                                                            ) => (string | NameAndType)[];

                                                                                                                                                                                                                                                                                                                                                                                                                                              method transformPrimitiveFields

                                                                                                                                                                                                                                                                                                                                                                                                                                              transformPrimitiveFields: (
                                                                                                                                                                                                                                                                                                                                                                                                                                              schemaType: GraphQLObjectType | GraphQLInterfaceType,
                                                                                                                                                                                                                                                                                                                                                                                                                                              fields: PrimitiveField[],
                                                                                                                                                                                                                                                                                                                                                                                                                                              unsetTypes?: boolean
                                                                                                                                                                                                                                                                                                                                                                                                                                              ) => (string | NameAndType)[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                method transformTypenameField

                                                                                                                                                                                                                                                                                                                                                                                                                                                transformTypenameField: (type: string, name: string) => (string | NameAndType)[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                  class SelectionSetToObject

                                                                                                                                                                                                                                                                                                                                                                                                                                                  class SelectionSetToObject<
                                                                                                                                                                                                                                                                                                                                                                                                                                                  Config extends ParsedDocumentsConfig = ParsedDocumentsConfig,
                                                                                                                                                                                                                                                                                                                                                                                                                                                  SelectionSetProcessorConfig extends BaseSelectionSetProcessorConfig = BaseSelectionSetProcessorConfig
                                                                                                                                                                                                                                                                                                                                                                                                                                                  > {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                    constructor

                                                                                                                                                                                                                                                                                                                                                                                                                                                    constructor(
                                                                                                                                                                                                                                                                                                                                                                                                                                                    _processor: BaseSelectionSetProcessor<SelectionSetProcessorConfig>,
                                                                                                                                                                                                                                                                                                                                                                                                                                                    _scalars: NormalizedScalarsMap,
                                                                                                                                                                                                                                                                                                                                                                                                                                                    _schema: GraphQLSchema,
                                                                                                                                                                                                                                                                                                                                                                                                                                                    _convertName: ConvertNameFn<BaseVisitorConvertOptions>,
                                                                                                                                                                                                                                                                                                                                                                                                                                                    _getFragmentSuffix: GetFragmentSuffixFn,
                                                                                                                                                                                                                                                                                                                                                                                                                                                    _loadedFragments: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                    name: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                    onType: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                    node: FragmentDefinitionNode;
                                                                                                                                                                                                                                                                                                                                                                                                                                                    isExternal: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                    importFrom?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                    }[],
                                                                                                                                                                                                                                                                                                                                                                                                                                                    _config: ParsedDocumentsConfig,
                                                                                                                                                                                                                                                                                                                                                                                                                                                    _parentSchemaType?: GraphQLNamedType,
                                                                                                                                                                                                                                                                                                                                                                                                                                                    _selectionSet?: SelectionSetNode
                                                                                                                                                                                                                                                                                                                                                                                                                                                    );

                                                                                                                                                                                                                                                                                                                                                                                                                                                      method buildFragmentSpreadsUsage

                                                                                                                                                                                                                                                                                                                                                                                                                                                      protected buildFragmentSpreadsUsage: (
                                                                                                                                                                                                                                                                                                                                                                                                                                                      spreads: FragmentSpreadNode[]
                                                                                                                                                                                                                                                                                                                                                                                                                                                      ) => Record<string, FragmentSpreadUsage[]>;
                                                                                                                                                                                                                                                                                                                                                                                                                                                      • The buildFragmentSpreadsUsage method is used to collect fields from fragment spreads in the selection set. It creates a record of fragment spread usages, which includes the fragment name, type name, and the selection nodes inside the fragment.

                                                                                                                                                                                                                                                                                                                                                                                                                                                      method buildFragmentTypeName

                                                                                                                                                                                                                                                                                                                                                                                                                                                      protected buildFragmentTypeName: (
                                                                                                                                                                                                                                                                                                                                                                                                                                                      name: string,
                                                                                                                                                                                                                                                                                                                                                                                                                                                      suffix: string,
                                                                                                                                                                                                                                                                                                                                                                                                                                                      typeName?: string
                                                                                                                                                                                                                                                                                                                                                                                                                                                      ) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                        method buildParentFieldName

                                                                                                                                                                                                                                                                                                                                                                                                                                                        protected buildParentFieldName: (typeName: string, parentName: string) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                          method buildSelectionSet

                                                                                                                                                                                                                                                                                                                                                                                                                                                          protected buildSelectionSet: (
                                                                                                                                                                                                                                                                                                                                                                                                                                                          parentSchemaType: GraphQLObjectType,
                                                                                                                                                                                                                                                                                                                                                                                                                                                          selectionNodes: Array<GroupedTypeNameNode>,
                                                                                                                                                                                                                                                                                                                                                                                                                                                          options: { unsetTypes?: boolean; parentFieldName?: string }
                                                                                                                                                                                                                                                                                                                                                                                                                                                          ) => {
                                                                                                                                                                                                                                                                                                                                                                                                                                                          typeInfo: { name: string; type: string };
                                                                                                                                                                                                                                                                                                                                                                                                                                                          fields: string[];
                                                                                                                                                                                                                                                                                                                                                                                                                                                          dependentTypes: DependentType[];
                                                                                                                                                                                                                                                                                                                                                                                                                                                          };

                                                                                                                                                                                                                                                                                                                                                                                                                                                            method buildTypeNameField

                                                                                                                                                                                                                                                                                                                                                                                                                                                            protected buildTypeNameField: (
                                                                                                                                                                                                                                                                                                                                                                                                                                                            type: GraphQLObjectType,
                                                                                                                                                                                                                                                                                                                                                                                                                                                            nonOptionalTypename: boolean,
                                                                                                                                                                                                                                                                                                                                                                                                                                                            queriedForTypename: boolean,
                                                                                                                                                                                                                                                                                                                                                                                                                                                            skipTypeNameForRoot: boolean
                                                                                                                                                                                                                                                                                                                                                                                                                                                            ) => { name: string; type: string };

                                                                                                                                                                                                                                                                                                                                                                                                                                                              method createNext

                                                                                                                                                                                                                                                                                                                                                                                                                                                              createNext: (
                                                                                                                                                                                                                                                                                                                                                                                                                                                              parentSchemaType: GraphQLNamedType,
                                                                                                                                                                                                                                                                                                                                                                                                                                                              selectionSet: SelectionSetNode
                                                                                                                                                                                                                                                                                                                                                                                                                                                              ) => SelectionSetToObject;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                method flattenSelectionSet

                                                                                                                                                                                                                                                                                                                                                                                                                                                                protected flattenSelectionSet: (
                                                                                                                                                                                                                                                                                                                                                                                                                                                                selections: ReadonlyArray<SelectionNode>,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                parentSchemaType?: GraphQLObjectType<any, any>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                ) => {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                selectionNodesByTypeName: Map<string, Array<GroupedTypeNameNode>>;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                selectionNodesByTypeNameConditional: Array<
                                                                                                                                                                                                                                                                                                                                                                                                                                                                Map<string, Array<GroupedTypeNameNode>>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                >;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  method getEmptyObjectType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  protected getEmptyObjectType: () => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    method getUnknownType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    protected getUnknownType: () => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      method selectionSetStringFromFields

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      protected selectionSetStringFromFields: (
                                                                                                                                                                                                                                                                                                                                                                                                                                                                      fields: (string | NameAndType)[]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                      ) => string | null;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        method transformFragmentSelectionSetToTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        transformFragmentSelectionSetToTypes: (
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        fragmentName: string,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        fragmentSuffix: string,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        declarationBlockConfig: DeclarationBlockConfig
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        ) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          method transformSelectionSet

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          transformSelectionSet: (fieldName: string) => {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                          mergedTypeString: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                          dependentTypes: DependentType[];
                                                                                                                                                                                                                                                                                                                                                                                                                                                                          isUnionType?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                          };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Interfaces

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface AvoidOptionalsConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface AvoidOptionalsConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property defaultValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              defaultValue?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property field

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                field?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property inputValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  inputValue?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property mutation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    mutation?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property object

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      object?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property query

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        query?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property resolvers

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          resolvers?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property subscription

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            subscription?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              interface BaseVisitorConvertOptions

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              interface BaseVisitorConvertOptions {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property useTypesPrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                useTypesPrefix?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property useTypesSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  useTypesSuffix?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface ClientSideBasePluginConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface ClientSideBasePluginConfig extends ParsedConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property dedupeOperationSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      dedupeOperationSuffix: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property documentMode

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        documentMode?: DocumentMode;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property documentNodeImport

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          documentNodeImport: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property documentVariablePrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            documentVariablePrefix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property documentVariableSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              documentVariableSuffix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property experimentalFragmentVariables

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                experimentalFragmentVariables?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property fragmentVariablePrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  fragmentVariablePrefix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property fragmentVariableSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    fragmentVariableSuffix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property globalNamespace

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      globalNamespace?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property gqlImport

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        gqlImport: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property importDocumentNodeExternallyFrom

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          importDocumentNodeExternallyFrom?: 'near-operation-file' | string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property importOperationTypesFrom

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            importOperationTypesFrom?: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property noExport

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              noExport: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property omitOperationSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                omitOperationSuffix: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property operationResultSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  operationResultSuffix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property optimizeDocumentNode

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    optimizeDocumentNode: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property pureMagicComment

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      pureMagicComment?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property unstable_omitDefinitions

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        unstable_omitDefinitions?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property unstable_onExecutableDocumentNode

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          unstable_onExecutableDocumentNode?: Unstable_OnExecutableDocumentNode;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface ConvertOptions

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface ConvertOptions {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property prefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              prefix?: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property suffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                suffix?: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property transformUnderscore

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  transformUnderscore?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface ConvertSchemaEnumToDeclarationBlockString

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface ConvertSchemaEnumToDeclarationBlockString {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property declarationBlockConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      declarationBlockConfig: DeclarationBlockConfig;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property enumName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        enumName: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property enumValues

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          enumValues: ParsedEnumValuesMap;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property futureProofEnums

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            futureProofEnums: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property ignoreEnumValuesFromSchema

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ignoreEnumValuesFromSchema: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property naming

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                naming: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                convert: ConvertFn;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                options: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                typesPrefix: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                typesSuffix: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                useTypesPrefix?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                useTypesSuffix?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property node

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  node: EnumTypeDefinitionNode;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property outputType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    outputType:
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    | 'string-literal'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    | 'native-numeric'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    | 'const'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    | 'native-const'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    | 'native';

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property schema

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      schema: GraphQLSchema;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        interface CustomDirectivesConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        interface CustomDirectivesConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property apolloUnmask

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          apolloUnmask?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • Adds integration with Apollo Client's @unmask directive when using Apollo Client's data masking feature. @unmask ensures fields marked by @unmask are available in the type definition. false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          interface DeclarationBlockConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          interface DeclarationBlockConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property blockTransformer

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            blockTransformer?: (block: string) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property blockWrapper

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              blockWrapper?: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property enumNameValueSeparator

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                enumNameValueSeparator?: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property ignoreExport

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ignoreExport?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface DeclarationKindConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface DeclarationKindConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property arguments

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      arguments?: DeclarationKind;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property directive

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        directive?: DeclarationKind;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property input

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          input?: DeclarationKind;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property interface

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface?: DeclarationKind;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property scalar

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              scalar?: DeclarationKind;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type?: DeclarationKind;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  interface ExternalParsedMapper

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  interface ExternalParsedMapper {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property default

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    default: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property import

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      import: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property isExternal

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        isExternal: true;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property source

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          source: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              interface FieldDefinitionResult

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              interface FieldDefinitionResult {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property node

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                node: FieldDefinitionNode;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property printContent

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  printContent: FieldDefinitionPrintFn;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface InterfaceOrVariable

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface InterfaceOrVariable {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property defaultValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      defaultValue?: ValueNode;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property directives

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        directives?: ReadonlyArray<DirectiveNode>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property name

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          name?: NameNode;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type: TypeNode;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property variable

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              variable?: VariableNode;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                interface InternalParsedMapper

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                interface InternalParsedMapper {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property isExternal

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  isExternal: false;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      interface NamingConventionMap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      interface NamingConventionMap {}
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      • false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property enumValues

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      enumValues?: 'keep' | NamingConventionResolvePath | NamingConventionFn;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property transformUnderscore

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        transformUnderscore?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property typeNames

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          typeNames?: 'keep' | NamingConventionResolvePath | NamingConventionFn;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface OperationAvoidOptionalsConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface OperationAvoidOptionalsConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property defaultValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              defaultValue?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property inputValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                inputValue?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property variableValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  variableValue?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface ParsedConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface ParsedConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property allowEnumStringTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      allowEnumStringTypes: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property convert

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        convert: ConvertFn;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property emitLegacyCommonJSImports

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          emitLegacyCommonJSImports?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property enumPrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            enumPrefix: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property enumSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              enumSuffix: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property externalFragments

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                externalFragments: LoadedFragment[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property fragmentImports

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  fragmentImports: ImportDeclaration<FragmentImport>[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property immutableTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    immutableTypes: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property importExtension

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      importExtension: '' | `.${string}`;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property includeExternalFragments

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        includeExternalFragments: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property inlineFragmentTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          inlineFragmentTypes: InlineFragmentTypeOptions;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property printFieldsOnNewLines

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            printFieldsOnNewLines: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property scalars

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              scalars: ParsedScalarsMap;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property typesPrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                typesPrefix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property typesSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  typesSuffix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property useTypeImports

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    useTypeImports: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      interface ParsedDocumentsConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      interface ParsedDocumentsConfig extends ParsedConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property avoidOptionals

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        avoidOptionals: NormalizedOperationAvoidOptionalsConfig;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property customDirectives

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          customDirectives: CustomDirectivesConfig;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property declarationKind

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            declarationKind: NormalizedOperationDeclarationKindConfig;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property dedupeOperationSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              dedupeOperationSuffix: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property experimentalFragmentVariables

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                experimentalFragmentVariables: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property exportFragmentSpreadSubTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  exportFragmentSpreadSubTypes: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property extractAllFieldsToTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    extractAllFieldsToTypes: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property extractAllFieldsToTypesCompact

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      extractAllFieldsToTypesCompact: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property generateOperationTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        generateOperationTypes: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property globalNamespace

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          globalNamespace: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property importSchemaTypesFrom

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            importSchemaTypesFrom: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property mergeFragmentTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              mergeFragmentTypes: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property namespacedImportName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                namespacedImportName: string | null;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property nonOptionalTypename

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  nonOptionalTypename: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property omitOperationSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    omitOperationSuffix: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property operationResultSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      operationResultSuffix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property skipTypeNameForRoot

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        skipTypeNameForRoot: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          interface ParsedImport

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          interface ParsedImport {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property moduleName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            moduleName: string | null;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property propName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              propName: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                interface ParsedResolversConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                interface ParsedResolversConfig extends ParsedConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property addInterfaceFieldResolverTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  addInterfaceFieldResolverTypes: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property addUnderscoreToArgsType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    addUnderscoreToArgsType: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property allResolversTypeName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      allResolversTypeName: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property avoidCheckingAbstractTypesRecursively

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        avoidCheckingAbstractTypesRecursively: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property avoidOptionals

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          avoidOptionals: NormalizedAvoidOptionalsConfig;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property contextType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            contextType: ParsedMapper;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property defaultMapper

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              defaultMapper: ParsedMapper | null;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property directiveContextTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                directiveContextTypes: Array<string>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property directiveResolverMappings

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  directiveResolverMappings: Record<string, string>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property enumValues

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    enumValues: ParsedEnumValuesMap;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property federation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      federation: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property fieldContextTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        fieldContextTypes: Array<string>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property immutableTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          immutableTypes: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property internalResolversPrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            internalResolversPrefix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property mappers

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              mappers: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              [typeName: string]: ParsedMapper;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property namespacedImportName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                namespacedImportName: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property optionalResolveType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  optionalResolveType: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property resolversNonOptionalTypename

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    resolversNonOptionalTypename: ResolversNonOptionalTypenameConfig;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property resolverTypeSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      resolverTypeSuffix: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property resolverTypeWrapperSignature

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        resolverTypeWrapperSignature: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property rootValueType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          rootValueType: ParsedMapper;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface ParsedTypesConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface ParsedTypesConfig extends ParsedConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property addTypename

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              addTypename: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property addUnderscoreToArgsType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                addUnderscoreToArgsType: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property declarationKind

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  declarationKind: DeclarationKindConfig;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property directiveArgumentAndInputFieldMappings

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    directiveArgumentAndInputFieldMappings: ParsedDirectiveArgumentAndInputFieldMappings;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property entireFieldWrapperValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      entireFieldWrapperValue: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property enumValues

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        enumValues: ParsedEnumValuesMap;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property fieldWrapperValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          fieldWrapperValue: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property ignoreEnumValuesFromSchema

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            ignoreEnumValuesFromSchema: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property nonOptionalTypename

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              nonOptionalTypename: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property onlyEnums

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                onlyEnums: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property onlyOperationTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  onlyOperationTypes: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property wrapEntireDefinitions

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    wrapEntireDefinitions: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property wrapFieldDefinitions

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      wrapFieldDefinitions: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        interface RawClientSideBasePluginConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        interface RawClientSideBasePluginConfig extends RawConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property dedupeOperationSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          dedupeOperationSuffix?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • false Set this configuration to true if you wish to make sure to remove duplicate operation name suffix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property documentMode

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          documentMode?: DocumentMode;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • graphQLTag Declares how DocumentNode are created:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            - graphQLTag: graphql-tag or other modules (check gqlImport) will be used to generate document nodes. If this is used, document nodes are generated on client side i.e. the module used to generate this will be shipped to the client - documentNode: document nodes will be generated as objects when we generate the templates. - documentNodeImportFragments: Similar to documentNode except it imports external fragments instead of embedding them. - external: document nodes are imported from an external file. To be used with importDocumentNodeExternallyFrom

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Note that some plugins (like typescript-graphql-request) also supports string for this parameter.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property documentNodeImport

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          documentNodeImport?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • graphql#DocumentNode Customize from which module will DocumentNode be imported from. This is useful if you want to use modules other than graphql, e.g. @graphql-typed-document-node.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property documentVariablePrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          documentVariablePrefix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • "" Changes the GraphQL operations variables prefix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property documentVariableSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          documentVariableSuffix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • Document Changes the GraphQL operations variables suffix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property experimentalFragmentVariables

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          experimentalFragmentVariables?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • false If set to true, it will enable support for parsing variables on fragments.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property fragmentVariablePrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          fragmentVariablePrefix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • "" Changes the GraphQL fragments variables prefix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property fragmentVariableSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          fragmentVariableSuffix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • FragmentDoc Changes the GraphQL fragments variables suffix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property gqlImport

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          gqlImport?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • graphql-tag#gql Customize from which module will gql be imported from. This is useful if you want to use modules other than graphql-tag, e.g. graphql.macro.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            ## graphql.macro

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            gqlImport: 'graphql.macro#gql'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            ## Gatsby

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            gqlImport: 'gatsby#graphql'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property importDocumentNodeExternallyFrom

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          importDocumentNodeExternallyFrom?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • "" This config should be used if documentMode is external. This has 2 usage:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            - any string: This would be the path to import document nodes from. This can be used if we want to manually create the document nodes e.g. Use graphql-tag in a separate file and export the generated document - 'near-operation-file': This is a special mode that is intended to be used with near-operation-file preset to import document nodes from those files. If these files are .graphql files, we make use of webpack loader.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            documentMode: 'external',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            importDocumentNodeExternallyFrom: 'path/to/document-node-file',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            documentMode: 'external',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            importDocumentNodeExternallyFrom: 'near-operation-file',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property importOperationTypesFrom

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          importOperationTypesFrom?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • "" This config is used internally by presets, but you can use it manually to tell codegen to prefix all base types that it's using. This is useful if you wish to generate base types from typescript-operations plugin into a different file, and import it from there.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property noExport

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          noExport?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • false Set this configuration to true if you wish to tell codegen to generate code with no export identifier.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property omitOperationSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          omitOperationSuffix?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • false Set this configuration to true if you wish to disable auto add suffix of operation name, like Query, Mutation, Subscription, Fragment.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property operationResultSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          operationResultSuffix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • "" Adds a suffix to generated operation result type names

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property optimizeDocumentNode

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          optimizeDocumentNode?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • true If you are using documentMode: documentNode | documentNodeImportFragments, you can set this to true to apply document optimizations for your GraphQL document. This will remove all "loc" and "description" fields from the compiled document, and will remove all empty arrays (such as directives, arguments and variableDefinitions).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property pureMagicComment

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          pureMagicComment?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          • false This config adds PURE magic comment to the static variables to enforce treeshaking for your bundler.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          interface RawConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          interface RawConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property allowEnumStringTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            allowEnumStringTypes?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property defaultScalarType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            defaultScalarType?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • Allows you to override the type that unknown scalars will have. unknown

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              defaultScalarType: 'any'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property emitLegacyCommonJSImports

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            emitLegacyCommonJSImports?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • Deprecated

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Please use importExtension instead. true Emit legacy common js imports. Default it will be true this way it ensure that generated code works with [non-compliant bundlers](https://github.com/dotansimha/graphql-code-generator/issues/8065).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property enumPrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            enumPrefix?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • true Allow you to disable prefixing for generated enums, works in combination with typesPrefix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ## Disable enum prefixes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              typesPrefix: 'I',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              enumPrefix: false
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property enumSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            enumSuffix?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • true Allow you to disable suffixing for generated enums, works in combination with typesSuffix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ## Disable enum suffixes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              typesSuffix: 'I',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              enumSuffix: false
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property externalFragments

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            externalFragments?: LoadedFragment[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property fragmentImports

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            fragmentImports?: ImportDeclaration<FragmentImport>[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property importExtension

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            importExtension?: '' | `.${string}`;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • Append this extension to all imports. Useful for ESM environments that require file extensions in import statements.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property includeExternalFragments

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            includeExternalFragments?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • false Whether to include external fragments in the generated code. External fragments are not defined in the same location as the operation definition.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property inlineFragmentTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            inlineFragmentTypes?: InlineFragmentTypeOptions;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • Whether fragment types should be inlined into other operations. "inline" is the default behavior and will perform deep inlining fragment types within operation type definitions. "combine" is the previous behavior that uses fragment type references without inlining the types (and might cause issues with deeply nested fragment that uses list types). "mask" transforms the types for use with fragment masking. Useful when masked types are needed when not using the "client" preset e.g. such as combining it with Apollo Client's data masking feature.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              string inline

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property namingConvention

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            namingConvention?: NamingConvention;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • change-case-all#pascalCase Allow you to override the naming convention of the output. You can either override all namings, or specify an object with specific custom naming convention per output. The format of the converter must be a valid module#method. Allowed values for specific output are: typeNames, enumValues. You can also use "keep" to keep all GraphQL names as-is. Additionally, you can set transformUnderscore to true if you want to override the default behavior, which is to preserve underscores.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Available case functions in change-case-all are camelCase, capitalCase, constantCase, dotCase, headerCase, noCase, paramCase, pascalCase, pathCase, sentenceCase, snakeCase, lowerCase, localeLowerCase, lowerCaseFirst, spongeCase, titleCase, upperCase, localeUpperCase and upperCaseFirst [See more](https://github.com/btxtiger/change-case-all)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ## Override All Names

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              namingConvention: 'change-case-all#lowerCase',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ## Upper-case enum values

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              namingConvention: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              typeNames: 'change-case-all#pascalCase',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              enumValues: 'change-case-all#upperCase',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ## Keep names as is

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              namingConvention: 'keep',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ## Remove Underscores

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              namingConvention: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              typeNames: 'change-case-all#pascalCase',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              transformUnderscore: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property printFieldsOnNewLines

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            printFieldsOnNewLines?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • false If you prefer to have each field in generated types printed on a new line, set this to true. This can be useful for improving readability of the resulting types, without resorting to running tools like Prettier on the output.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property scalars

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            scalars?: ScalarsMap;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • Extends or overrides the built-in scalars and custom GraphQL scalars to a custom type.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              scalars: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ID: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              input: 'string',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              output: 'string | number'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              DateTime: 'Date',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              JSON: '{ [key: string]: any }',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property strictScalars

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            strictScalars?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • Makes scalars strict.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If scalars are found in the schema that are not defined in scalars an error will be thrown during codegen. false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              strictScalars: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property typesPrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            typesPrefix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • "" Prefixes all the generated types.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              typesPrefix: 'I',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property typesSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            typesSuffix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • "" Suffixes all the generated types.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              typesSuffix: 'I',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property useTypeImports

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            useTypeImports?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • useTypeImports boolean false Will use import type {} rather than import {} when importing only types. This gives compatibility with TypeScript's "importsNotUsedAsValues": "error" option

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              useTypeImports: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface RawDocumentsConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface RawDocumentsConfig extends RawConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property avoidOptionals

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              avoidOptionals?: boolean | OperationAvoidOptionalsConfig;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • This will cause the generator to avoid using TypeScript optionals (?) on types, so the following definition: type A { myField: String } will output myField: Maybe<string> instead of myField?: Maybe<string>. false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ## Override all definition types

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file.ts': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                plugins: ['typescript-operations'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                avoidOptionals: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ## Override only specific definition types

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file.ts': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                plugins: ['typescript-operations'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                avoidOptionals: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                variableValue: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                inputValue: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                defaultValue: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property customDirectives

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              customDirectives?: CustomDirectivesConfig;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Configures behavior for use with custom directives from various GraphQL libraries.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file.ts': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                plugins: ['typescript'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                customDirectives: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                apolloUnmask: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property declarationKind

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              declarationKind?: OperationDeclarationKind | OperationDeclarationKindConfig;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Overrides the default output for various GraphQL types. 'type' ## Override all declarations

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                declarationKind: 'interface'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ## Override only specific declarations

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                declarationKind: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                input: 'interface',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                result: 'type'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property dedupeOperationSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              dedupeOperationSuffix?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false Set this configuration to true if you wish to make sure to remove duplicate operation name suffix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property experimentalFragmentVariables

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              experimentalFragmentVariables?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false If set to true, it will enable support for parsing variables on fragments.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property exportFragmentSpreadSubTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              exportFragmentSpreadSubTypes?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false If set to true, it will export the sub-types created in order to make it easier to access fields declared under fragment spread.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property extractAllFieldsToTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              extractAllFieldsToTypes?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false Extract all field types to their own types, instead of inlining them. This helps to reduce type duplication, and makes type errors more readable. It can also significantly reduce the size of the generated code, the generation time, and the typechecking time.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property extractAllFieldsToTypesCompact

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              extractAllFieldsToTypesCompact?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false Generates type names using only field names, omitting GraphQL type names. This matches the naming convention used by Apollo Tooling. For example, instead of Query_company_Company_office_Office_location_Location, it generates Query_company_office_location.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                When this option is enabled, extractAllFieldsToTypes is automatically enabled as well.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property generateOperationTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generateOperationTypes?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Whether to generate operation types such as Variables, Query/Mutation/Subscription selection set, and Fragment types This can be used with importSchemaTypesFrom to generate shared used Enums and Input. true

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file.ts': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                plugins: ['typescript-operations'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generateOperationTypes: false,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property globalNamespace

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              globalNamespace?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false Puts all generated code under global namespace. Useful for Stencil integration.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                globalNamespace: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property importSchemaTypesFrom

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              importSchemaTypesFrom?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • The absolute (prefixed with ~) or relative path from cwd to the shared used Enums and Input (See generateOperationTypes). true

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file.ts': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                plugins: ['typescript-operations'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                importSchemaTypesFrom: './path/to/shared-types.ts', // relative
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                importSchemaTypesFrom: '~@my-org/package' // absolute
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property mergeFragmentTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              mergeFragmentTypes?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false If set to true, merge equal fragment interfaces.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property namespacedImportName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              namespacedImportName?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Prefixes all GraphQL related generated types with that value, as namespaces import. You can use this feature to allow separation of plugins to different files (See importSchemaTypesFrom) 'Types' (if importSchemaTypesFrom is set)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file.ts': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                plugins: ['typescript-operations'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                importSchemaTypesFrom: './path/to/shared-types.ts',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                namespacedImportName: 'Types'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property nonOptionalTypename

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              nonOptionalTypename?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false Automatically adds __typename field to the generated types, even when they are not specified in the selection set, and makes it non-optional

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                nonOptionalTypename: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property omitOperationSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              omitOperationSuffix?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false Set this configuration to true if you wish to disable auto add suffix of operation name, like Query, Mutation, Subscription, Fragment.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property operationResultSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              operationResultSuffix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • "" Adds a suffix to generated operation result type names

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property skipTypeNameForRoot

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              skipTypeNameForRoot?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • false Avoid adding __typename for root types. This is ignored when a selection explicitly specifies __typename.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                skipTypeNameForRoot: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              interface RawResolversConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              interface RawResolversConfig extends RawConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property addInterfaceFieldResolverTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                addInterfaceFieldResolverTypes?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • If true, add field resolver types to Interfaces. By default, GraphQL Interfaces do not trigger any field resolvers, meaning every implementing type must implement the same resolver for the shared fields.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Some tools provide a way to change the default behaviour by making GraphQL Objects inherit missing resolvers from their Interface types. In these cases, it is fine to turn this option to true.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  For example, if you are using @graphql-tools/schema#makeExecutableSchema with inheritResolversFromInterfaces: true, you can make addInterfaceFieldResolverTypes: true as well https://the-guild.dev/graphql/tools/docs/generate-schema#makeexecutableschema

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  plugins: ['typescript', 'typescript-resolver'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  addInterfaceFieldResolverTypes: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  boolean false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property addUnderscoreToArgsType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                addUnderscoreToArgsType?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Adds _ to generated Args types in order to avoid duplicate identifiers.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  addUnderscoreToArgsType: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property allResolversTypeName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                allResolversTypeName?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Resolvers The type name to use when exporting all resolvers signature as unified type.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property avoidCheckingAbstractTypesRecursively

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                avoidCheckingAbstractTypesRecursively?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • boolean false If true, recursively goes through all object type's fields, checks if they have abstract types and generates expected types correctly. This may not work for cases where provided default mapper types are also nested e.g. defaultMapper: DeepPartial<{T}> or defaultMapper: Partial<{T}>.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property avoidOptionals

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                avoidOptionals?: boolean | AvoidOptionalsConfig;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • This will cause the generator to avoid using optionals (?), so all field resolvers must be implemented in order to avoid compilation errors. false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Override all definition types

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  plugins: ['typescript', 'typescript-resolver'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  avoidOptionals: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Override only specific definition types

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  plugins: ['typescript', 'typescript-resolver'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  avoidOptionals: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  field: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  inputValue: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  object: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  defaultValue: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  query: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  mutation: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  subscription: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property contextType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                contextType?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Use this configuration to set a custom type for your context, and it will affect all the resolvers, without the need to override it using generics each time. If you wish to use an external type and import it from another file, you can use add plugin and add the required import statement, or you can use a module#type syntax.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Custom Context Type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  contextType: 'MyContext'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Custom Context Type by Path

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Note that the path should be relative to the generated file.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  contextType: './my-types#MyContext'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property customDirectives

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                customDirectives?: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                semanticNonNull?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Configures behavior for custom directives from various GraphQL libraries. ## @semanticNonNull First, install graphql-sock peer dependency:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  npm install -D graphql-sock

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Now, you can enable support for @semanticNonNull directive:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file.ts': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  plugins: ['typescript-resolvers'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  customDirectives: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  semanticNonNull: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property defaultMapper

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                defaultMapper?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Allow you to set the default mapper when it's not being override by mappers or generics. You can specify a type name, or specify a string in module#type or module#namespace#type format. The default value of mappers is the TypeScript type generated by typescript package.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Replace with any

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  defaultMapper: 'any',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Custom Base Object

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  defaultMapper: './my-file#BaseObject',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Wrap default types with Partial

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  You can also specify a custom wrapper for the original type, without overriding the original generated types, use {T} to specify the identifier. (for flow, use $Shape<{T}>)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  defaultMapper: 'Partial<{T}>',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Allow deep partial with utility-types

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  plugins: ['typescript', 'typescript-resolver', { add: { content: "import { DeepPartial } from 'utility-types';" } }],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  defaultMapper: 'DeepPartial<{T}>',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  avoidCheckingAbstractTypesRecursively: true // required if you have complex nested abstract types
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property directiveContextTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                directiveContextTypes?: Array<string>;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Use this to set a custom type for a specific field context decorated by a directive. It will only affect the targeted resolvers. You can either use Field.Path#ContextTypeName or Field.Path#ExternalFileName#ContextTypeName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ContextTypeName should by a generic Type that take the context or field context type as only type parameter.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Directive Context Extender

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  directiveContextTypes: ['myCustomDirectiveName#./my-file#CustomContextExtender']
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property directiveResolverMappings

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                directiveResolverMappings?: Record<string, string>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property enumValues

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                enumValues?: EnumValuesMap;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Overrides the default value of enum values declared in your GraphQL schema, supported in this plugin because of the need for integration with typescript package. See documentation under typescript plugin for more information and examples.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property federation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                federation?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • false Supports Apollo Federation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property fieldContextTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                fieldContextTypes?: Array<string>;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Use this to set a custom type for a specific field context. It will only affect the targeted resolvers. You can either use Field.Path#ContextTypeName or Field.Path#ExternalFileName#ContextTypeName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Custom Field Context Types

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  fieldContextTypes: ['MyType.foo#CustomContextType', 'MyType.bar#./my-file#ContextTypeOne']
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property immutableTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                immutableTypes?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • false Generates immutable types by adding readonly to properties and uses ReadonlyArray.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property internalResolversPrefix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                internalResolversPrefix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • string '__' Defines the prefix value used for __resolveType and __isTypeOf resolvers. If you are using mercurius-js, please set this field to empty string for better compatibility.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property mappers

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                mappers?: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                [typeName: string]: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Replaces a GraphQL type usage with a custom type, allowing you to return custom object from your resolvers. You can use both module#type and module#namespace#type syntax.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Custom Context Type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  mappers: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  User: './my-models#UserDbObject',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Book: './my-models#Collections',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property mapperTypeSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                mapperTypeSuffix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Adds a suffix to the imported names to prevent name clashes.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  mapperTypeSuffix: 'Model'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property namespacedImportName

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                namespacedImportName?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • '' Prefixes all GraphQL related generated types with that value, as namespaces import. You can use this feature to allow separation of plugins to different files.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property optionalResolveType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                optionalResolveType?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • false Sets the __resolveType field as optional field.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property resolversNonOptionalTypename

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                resolversNonOptionalTypename?: boolean | ResolversNonOptionalTypenameConfig;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Makes __typename of resolver mappings non-optional without affecting the base types. false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Enable for all

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  plugins: ['typescript', 'typescript-resolver'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  resolversNonOptionalTypename: true // or { unionMember: true, interfaceImplementingType: true }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Enable except for some types

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  plugins: ['typescript', 'typescript-resolver'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  resolversNonOptionalTypename: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  unionMember: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  interfaceImplementingType: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  excludeTypes: ['MyType'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property resolverTypeSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                resolverTypeSuffix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Resolvers Suffix we add to each generated type resolver.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property resolverTypeWrapperSignature

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                resolverTypeWrapperSignature?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Promise | T Allow you to override resolverTypeWrapper definition.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property rootValueType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                rootValueType?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Use this configuration to set a custom type for the rootValue, and it will affect resolvers of all root types (Query, Mutation and Subscription), without the need to override it using generics each time. If you wish to use an external type and import it from another file, you can use add plugin and add the required import statement, or you can use both module#type or module#namespace#type syntax.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Custom RootValue Type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  rootValueType: 'MyRootValue'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ## Custom RootValue Type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  rootValueType: './my-types#MyRootValue'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property showUnusedMappers

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                showUnusedMappers?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • Warns about unused mappers. true

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  plugins: ['typescript', 'typescript-resolver'],
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  showUnusedMappers: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                interface RawTypesConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                interface RawTypesConfig extends RawConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property addUnderscoreToArgsType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  addUnderscoreToArgsType?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • Adds _ to generated Args types in order to avoid duplicate identifiers.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## With Custom Values

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    addUnderscoreToArgsType: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property declarationKind

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  declarationKind?: DeclarationKind | DeclarationKindConfig;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • Overrides the default output for various GraphQL elements.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## Override all declarations

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    declarationKind: 'interface'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## Override only specific declarations

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    declarationKind: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type: 'interface',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    input: 'interface'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property directiveArgumentAndInputFieldMappings

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  directiveArgumentAndInputFieldMappings?: DirectiveArgumentAndInputFieldMappings;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • Replaces a GraphQL scalar with a custom type based on the applied directive on an argument or input field.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    You can use both module#type and module#namespace#type syntax. Will NOT work with introspected schemas since directives are not exported. Only works with directives on ARGUMENT_DEFINITION or INPUT_FIELD_DEFINITION.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    **WARNING:** Using this option does only change the type definitions.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    For actually ensuring that a type is correct at runtime you will have to use schema transforms (e.g. with [@graphql-tools/utils mapSchema](https://graphql-tools.com/docs/schema-directives)) that apply those rules! Otherwise, you might end up with a runtime type mismatch which could cause unnoticed bugs or runtime errors.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Please use this configuration option with care!

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## Custom Context Type\

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    directiveArgumentAndInputFieldMappings: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    AsNumber: 'number',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    AsComplex: './my-models#Complex',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property directiveArgumentAndInputFieldMappingTypeSuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  directiveArgumentAndInputFieldMappingTypeSuffix?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • Adds a suffix to the imported names to prevent name clashes.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    directiveArgumentAndInputFieldMappings: 'Model'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property entireFieldWrapperValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  entireFieldWrapperValue?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • entireFieldWrapperValue string Allow to override the type value of EntireFieldWrapper. This wrapper applies outside of Array and Maybe unlike fieldWrapperValue, that will wrap the inner type. T | Promise | (() => T | Promise)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Example 1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Only allow values

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    entireFieldWrapperValue: 'T',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property enumValues

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  enumValues?: EnumValuesMap;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • Overrides the default value of enum values declared in your GraphQL schema. You can also map the entire enum to an external type by providing a string that of module#type.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## With Custom Values

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    enumValues: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    MyEnum: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    A: 'foo'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## With External Enum

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    enumValues: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    MyEnum: './my-file#MyCustomEnum',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## Import All Enums from a file

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    enumValues: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    MyEnum: './my-file',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property fieldWrapperValue

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  fieldWrapperValue?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • Allow you to add wrapper for field type, use T as the generic value. Make sure to set wrapFieldDefinitions to true in order to make this flag work. T

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## Allow Promise

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    wrapFieldDefinitions: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    fieldWrapperValue: 'T | Promise<T>',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property ignoreEnumValuesFromSchema

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ignoreEnumValuesFromSchema?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • This will cause the generator to ignore enum values defined in GraphQLSchema false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## Ignore enum values from schema

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ignoreEnumValuesFromSchema: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property nonOptionalTypename

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  nonOptionalTypename?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • false Automatically adds __typename field to the generated types, even when they are not specified in the selection set, and makes it non-optional

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    nonOptionalTypename: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property onlyEnums

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  onlyEnums?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • This will cause the generator to emit types for enums only false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## Override all definition types

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    onlyEnums: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property onlyOperationTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  onlyOperationTypes?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • This will cause the generator to emit types for operations only (basically only enums and scalars) false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## Override all definition types

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    onlyOperationTypes: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property skipTypename

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  skipTypename?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • false Does not add __typename to the generated types, unless it was specified in the selection set.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    skipTypename: true
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property wrapEntireFieldDefinitions

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  wrapEntireFieldDefinitions?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • wrapEntireFieldDefinitions boolean Set to true in order to wrap field definitions with EntireFieldWrapper. This is useful to allow return types such as Promises and functions for fields. Differs from wrapFieldDefinitions in that this wraps the entire field definition if i.e. the field is an Array, while wrapFieldDefinitions will wrap every single value inside the array. true

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Example 1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Enable wrapping entire fields

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    wrapEntireFieldDefinitions: false,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property wrapFieldDefinitions

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  wrapFieldDefinitions?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • Set to true in order to wrap field definitions with FieldWrapper. This is useful to allow return types such as Promises and functions. false

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ## Enable wrapping fields

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    import type { CodegenConfig } from '@graphql-codegen/cli';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    const config: CodegenConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // ...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    generates: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    'path/to/file': {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    // plugins...
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    config: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    wrapFieldDefinitions: true,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    },
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    export default config;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  interface ResolversNonOptionalTypenameConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  interface ResolversNonOptionalTypenameConfig {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property excludeTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    excludeTypes?: string[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property interfaceImplementingType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      interfaceImplementingType?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property unionMember

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        unionMember?: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          interface RootResolver

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          interface RootResolver {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property content

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            content: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property generatedResolverTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              generatedResolverTypes: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              resolversMap: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              name: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              userDefined: Record<
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              string,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              name: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              hasIsTypeOf: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              federation?: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              hasResolveReference: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              >;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Enums

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                enum DocumentMode

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                enum DocumentMode {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                graphQLTag = 'graphQLTag',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                documentNode = 'documentNode',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                documentNodeImportFragments = 'documentNodeImportFragments',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                external = 'external',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                string = 'string',
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                }

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  member documentNode

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  documentNode = 'documentNode'

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    member documentNodeImportFragments

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    documentNodeImportFragments = 'documentNodeImportFragments'

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      member external

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      external = 'external'

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        member graphQLTag

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        graphQLTag = 'graphQLTag'

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          member string

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          string = 'string'

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Type Aliases

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type ConvertFn

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type ConvertFn<T = {}> = (
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            node: ASTNode | string,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            options?: ConvertOptions & T
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            ) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              type ConvertNameFn

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              type ConvertNameFn<T = {}> = ConvertFn<T>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type DeclarationKind

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type DeclarationKind = 'type' | 'interface' | 'class' | 'abstract class';

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type DirectiveArgumentAndInputFieldMappings

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type DirectiveArgumentAndInputFieldMappings = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  [name: string]: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • A map between the GraphQL directive name and the identifier that should be used

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type EnumValuesMap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type EnumValuesMap<AdditionalProps = {}> =
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | string
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  [enumName: string]:
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | string
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | ({
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  [key: string]: string | number;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  } & AdditionalProps);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • A raw configuration for enumValues map - can be represented with a single string value for a file path, a map between enum name and a file path, or a map between enum name and an object with explicit enum values.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type FragmentImport

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type FragmentImport = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  name: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  kind: 'type' | 'document';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type GetFragmentSuffixFn

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type GetFragmentSuffixFn = (node: FragmentDefinitionNode | string) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      type GroupedMappers

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      type GroupedMappers = Record<
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      string,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      identifier: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      asDefault?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      }[]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      >;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        type ImportDeclaration

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        type ImportDeclaration<T = string> = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        outputPath: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        importSource: ImportSource<T>;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        baseOutputDir: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        baseDir: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        typesImport: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        emitLegacyCommonJSImports?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        importExtension: '' | `.${string}`;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          type ImportSource

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          type ImportSource<T = string> = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          /**
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          * Source path, relative to the `baseOutputDir`
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          */
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          path: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          /**
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          * Namespace to import source as
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          */
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          namespace?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          /**
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          * Entity names to import
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          */
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          identifiers?: T[];
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type InlineFragmentTypeOptions

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type InlineFragmentTypeOptions = 'inline' | 'combine' | 'mask';

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              type LinkField

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              type LinkField = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              alias: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              name: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              type: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              selectionSet: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type LoadedFragment

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type LoadedFragment<AdditionalFields = {}> = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                name: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                onType: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                node: FragmentDefinitionNode;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                isExternal: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                importFrom?: string | null;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                } & AdditionalFields;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type NameAndType

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type NameAndType = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  name: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type NamingConvention

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type NamingConvention = string | NamingConventionFn | NamingConventionMap;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      type NamingConventionFn

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      type NamingConventionFn = (str: string) => string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        type NamingConventionResolvePath

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        type NamingConventionResolvePath = string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          type NormalizedAvoidOptionalsConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          type NormalizedAvoidOptionalsConfig = Required<AvoidOptionalsConfig>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type NormalizedOperationAvoidOptionalsConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type NormalizedOperationAvoidOptionalsConfig =
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Required<OperationAvoidOptionalsConfig>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              type NormalizedOperationDeclarationKindConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              type NormalizedOperationDeclarationKindConfig =
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Required<OperationDeclarationKindConfig>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type NormalizedScalarsMap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type NormalizedScalarsMap = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                [name: string]: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                input: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                output: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                • A normalized map between GraphQL scalar name and the identifier name

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type OperationDeclarationKind

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type OperationDeclarationKind = 'type' | 'interface';

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type OperationDeclarationKindConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type OperationDeclarationKindConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  input?: OperationDeclarationKind;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  result?: OperationDeclarationKind;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type ParsedDirectiveArgumentAndInputFieldMappings

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type ParsedDirectiveArgumentAndInputFieldMappings = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    [name: string]: ParsedMapper;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    • Parsed directives map - a mapping between GraphQL directive name and the parsed mapper object, including all required information for generating code for that mapping.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type ParsedEnumValuesMap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    type ParsedEnumValuesMap = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    [enumName: string]: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    mappedValues?: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    [valueName: string]: string | number;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    typeIdentifier: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    typeIdentifierConverted: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    sourceIdentifier?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    sourceFile?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    importIdentifier?: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    isDefault?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      type ParsedMapper

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      type ParsedMapper = InternalParsedMapper | ExternalParsedMapper;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        type ParsedScalarsMap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        type ParsedScalarsMap = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        [name: string]: {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        input: ParsedMapper;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        output: ParsedMapper;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        • Parsed scalars map - a mapping between GraphQL scalar name and the parsed mapper object, including all required information for generting code for that mapping.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        type PrimitiveAliasedFields

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        type PrimitiveAliasedFields = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        isConditional: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        alias: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        fieldName: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          type PrimitiveField

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          type PrimitiveField = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          isConditional: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          fieldName: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type ProcessResult

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type ProcessResult = null | Array<NameAndType | string>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              type ResolverParentTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              type ResolverParentTypes = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              [gqlType: string]: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type ResolverTypes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                type ResolverTypes = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                [gqlType: string]: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type ScalarsMap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type ScalarsMap =
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | string
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  [name: string]:
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | string
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  input: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  output: string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  • Scalars map or a string, a map between the GraphQL scalar name and the identifier that should be used

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type SelectionSetProcessorConfig

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type SelectionSetProcessorConfig = {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  namespacedImportName: string | null;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  convertName: ConvertNameFn<any>;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  enumPrefix: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  enumSuffix: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  scalars: NormalizedScalarsMap;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  formatNamedField(params: { name: string; isOptional?: boolean }): string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  wrapTypeWithModifiers(
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  baseType: string,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type: GraphQLOutputType | GraphQLNamedType
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ): string;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  printFieldsOnNewLines?: boolean;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  };

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Package Files (24)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Dependencies (10)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Dev Dependencies (0)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    No dev dependencies.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Peer Dependencies (1)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Badge

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@graphql-codegen/visitor-plugin-common.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    • Markdown
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@graphql-codegen/visitor-plugin-common)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    • HTML
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      <a href="https://www.jsdocs.io/package/@graphql-codegen/visitor-plugin-common"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>