-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added operation names type for custom
interceptGraphql
command
This will allow type checking and autocompleteting the operation name when writing intercepts for graphql
- Loading branch information
1 parent
5b940a5
commit 491fb77
Showing
3 changed files
with
11 additions
and
4 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
import { operationNames } from "./generated/graphql"; | ||
|
||
type QueryOperations = keyof typeof operationNames.Query; | ||
type MutationOperations = keyof typeof operationNames.Mutation; | ||
export type Operations = QueryOperations | MutationOperations; |