Add typedDocumentStringTemplate to re-use across client plugins - #10863
Merged
Conversation
🦋 Changeset detectedLatest commit: c7de66d The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Contributor
🚀 Snapshot Release (
|
| Package | Version | Info |
|---|---|---|
@graphql-codegen/visitor-plugin-common |
7.1.0-alpha-20260601135711-c7de66d21cb5b847190ede1d086709fee469cc0e |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/typed-document-node |
7.0.3-alpha-20260601135711-c7de66d21cb5b847190ede1d086709fee469cc0e |
npm ↗︎ unpkg ↗︎ |
dotansimha
approved these changes
Jun 1, 2026
Contributor
💻 Website PreviewThe latest changes are available as preview in: https://pr-10863.graphql-code-generator.pages.dev |
negezor
pushed a commit
to senkuro-dev/graphql-code-generator
that referenced
this pull request
Aug 14, 2026
…nsimha#10863) * Add typedDocumentStringTemplate to re-use across client plugins that need it * Add changeset
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Since
visitor-plugin-common~v3, we've wrapped strings inTypedDocumentNodeto type document strings with GraphQLResultandVariables. This is useful for clients that take strings, instead of ASTs. Most relevant PR I could find is this oneHowever, community packages never got these
TypedDocumentNodeimplemented. So they were stuck onvisitor-plugin-commonv2.x for a long time.This PR extracts the
TypedDocumentNodetemplate tovisitor-plugin-commonso they could be shared with community pluginsRelated dotansimha/graphql-code-generator-community#1410, #10759
Type of change
How Has This Been Tested?