From e6f80af0769a9f7e6a910ade3cfdbf76b0ba8ccf Mon Sep 17 00:00:00 2001 From: Thomas Seillan Date: Sun, 7 Feb 2021 15:21:27 +0100 Subject: [PATCH 1/2] GraphQLHookOptions - added refetchQueries type. --- packages/web/src/components/GraphQLHooksProvider.tsx | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/packages/web/src/components/GraphQLHooksProvider.tsx b/packages/web/src/components/GraphQLHooksProvider.tsx index b6433f5edc30..9ee4ea94e91c 100644 --- a/packages/web/src/components/GraphQLHooksProvider.tsx +++ b/packages/web/src/components/GraphQLHooksProvider.tsx @@ -1,8 +1,17 @@ import type { DocumentNode } from 'graphql' + +export type PureQueryOptions = { + query: DocumentNode; + variables?: { [key: string]: any }; + context?: any; +} + export interface GraphQLHookOptions { variables?: Record + refetchQueries?: Array } + export interface OperationResult { data?: TData loading: boolean From 03152cb8aca7f68328af268cf1464fbea09506d8 Mon Sep 17 00:00:00 2001 From: Thomas Seillan Date: Sun, 7 Feb 2021 18:04:09 +0100 Subject: [PATCH 2/2] Lint - fixes. --- packages/web/src/components/GraphQLHooksProvider.tsx | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/packages/web/src/components/GraphQLHooksProvider.tsx b/packages/web/src/components/GraphQLHooksProvider.tsx index 9ee4ea94e91c..d001f5fc22d2 100644 --- a/packages/web/src/components/GraphQLHooksProvider.tsx +++ b/packages/web/src/components/GraphQLHooksProvider.tsx @@ -1,10 +1,9 @@ import type { DocumentNode } from 'graphql' - export type PureQueryOptions = { - query: DocumentNode; - variables?: { [key: string]: any }; - context?: any; + query: DocumentNode + variables?: { [key: string]: any } + context?: any } export interface GraphQLHookOptions {