Skip to content

Conversation

JoviDeCroock
Copy link
Member

Adds built-in support for graphql/graphql-spec#1170

Supports descriptions on

  • FragmentDefinition
  • VariableDefinition
  • non-shorthand OperationDefinition

@JoviDeCroock JoviDeCroock requested a review from kitten July 23, 2025 21:29
Copy link

changeset-bot bot commented Jul 23, 2025

🦋 Changeset detected

Latest commit: dd64199

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@0no-co/graphql.web Minor

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

}
}
"Time machine details."
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interestingly this seems to add newlines at the front and end when parsed

do {
let _description: ast.StringValueNode | undefined;
if (input.charCodeAt(idx) === 34 /*'"'*/) {
_description = value(true) as ast.StringValueNode;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would we want to add an invariant for checking that this can only be a string or split the string out?

@JoviDeCroock JoviDeCroock force-pushed the support-executable-descriptions branch 2 times, most recently from 41fffb8 to c802ab1 Compare July 24, 2025 11:35
@JoviDeCroock JoviDeCroock merged commit 2c03c75 into main Jul 29, 2025
1 check passed
@github-actions github-actions bot mentioned this pull request Jul 29, 2025
@JoviDeCroock JoviDeCroock deleted the support-executable-descriptions branch July 29, 2025 10:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants