forked from graphql/graphql-js
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
introspection should match the ExecutorSchema (#170)
...rather than the GraphQLSchema. Relevant only if an explicit ExecutorSchema is passed, otherwise the ExecutorSchema is generated from the GraphQLSchema. This also adds a new `__directive(name: "someDirective")` introspection root field to request info about a single named directive, parallel to the `__type(name: "someType")` introspection root field. This currently does not pass validation and is used only to facilitate testing.
- Loading branch information
Showing
8 changed files
with
2,365 additions
and
86 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
'graphql-executor': patch | ||
--- | ||
|
||
introspection should track the ExecutorSchema rather than the GraphQLSchema | ||
|
||
...in case of any discrepancy. When an explicit ExecutorSchema is passed, the GraphQLSchema should essentially be ignored, required in essence only to satisfy TS typings. If an explicit ExecutorSchema is not passed, it is generated from the GraphQLSchema, and so there would be no discrepancy. |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import { versionInfo } from 'graphql'; | ||
|
||
export function handlePre16<T>(postV16: T | undefined, preV16: T | undefined) { | ||
/* c8 ignore next */ | ||
return versionInfo.major >= 16 ? postV16 : preV16; | ||
} |
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.