unstale

npm / @graphql-codegen/visitor-plugin-common

@graphql-codegen/visitor-plugin-common

What changed in @graphql-codegen/visitor-plugin-common 7, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-21.

1 breaking3 new APIs and options1 behavior and defaults22 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli 0.2.1 on npm

@graphql-codegen/visitor-plugin-common 727 changes

Breaking changes 1

  • Throws a descriptive error when an enum value is not defined on the schema's enum, and treats a non-enum schema type with the enum's name as having no schema enum.

    7.2.10release notes

New APIs and options 3

  • Adds an option that, with documentMode: graphQLTag, includes spread fragments in each fragment document so it can be used on its own; defaults to false, and operation documents do not change.

    7.4.0release notes

  • Adds plainString mode, generating documents as plain template strings with embedded fragments instead of TypedDocumentString instances; each document is typed as string.

    7.3.0release notes

  • Returns the default reason for a @deprecated directive without arguments.

    7.2.10release notes

Behavior and default changes 1

Fixes and other changes 22

  • SchemaDefinition() and SchemaExtension() are typed to return null instead of any.

    7.2.10release notes

  • May return null, matching its existing return behavior.

    7.2.10release notes

  • The typeCache key type is Location | undefined.

    7.2.10release notes

  • SchemaDefinition() and SchemaExtension() are typed to return null instead of any.

    7.2.10release notes

  • Its parameter is typed as string[] | null | undefined, matching its empty-string handling.

    7.2.10release notes

  • Accepts an undefined scalars mapping and uses only the defaults and the schema.

    7.2.10release notes

  • Accepts nullish identifier and source, and throws a descriptive error when either is missing.

    7.2.10release notes

  • Treats an enum node without values as empty instead of throwing.

    7.2.10release notes

  • When blockTransformer is undefined, the block is returned unchanged instead of throwing.

    7.2.10release notes

  • Fields are typed as string | null, with _name typed as string | NameNode | null.

    7.2.10release notes

  • Accepts null, which renders the same as no block.

    7.2.10release notes

  • Treats missing identifiers as empty.

    7.2.10release notes

  • The type parameter accepts null, which graphql 15's schema.getType() can return.

    7.2.10release notes

  • Returns false instead of undefined.

    7.2.10release notes

  • getName and transform may return null, matching their existing return behavior.

    7.2.10release notes

  • Emits an empty string instead of the text undefined or null when a variable has no name or type identifier.

    7.2.10release notes

  • Throws a descriptive error when a document file has no parsed document.

    7.2.10release notes

  • These fields accept null, matching values already emitted by parseEnumValues.

    7.2.10release notes

  • Returned nodes use description: undefined instead of any.

    7.2.10release notes

  • The returned typeInfo is typed as { name: string; type: string } | null.

    7.2.10release notes

  • Accepts undefined and null, which it handles by returning an empty string.

    7.2.10release notes

  • The default key uses String(item).

    7.2.10release notes