diff --git a/examples/frontend/src/github/githubContext.ts b/examples/frontend/src/github/githubContext.ts index 79ff533..7d1a31e 100644 --- a/examples/frontend/src/github/githubContext.ts +++ b/examples/frontend/src/github/githubContext.ts @@ -1,7 +1,6 @@ import { skipToken, type DefaultError, - type Enabled, type QueryKey, type UseQueryOptions, } from "@tanstack/react-query"; @@ -31,7 +30,12 @@ export type GithubContext< * Set this to `false` to disable automatic refetching when the query mounts or changes query keys. * Defaults to `true`. */ - enabled?: Enabled; + enabled?: UseQueryOptions< + TQueryFnData, + TError, + TQueryFnData, + TQueryKey + >["enabled"]; }; }; diff --git a/plugins/typescript/src/templates/context.ts b/plugins/typescript/src/templates/context.ts index 1f3f872..4f59096 100644 --- a/plugins/typescript/src/templates/context.ts +++ b/plugins/typescript/src/templates/context.ts @@ -8,7 +8,6 @@ export const getContext = ( `import { skipToken, type DefaultError, - type Enabled, type QueryKey, type UseQueryOptions, } from "@tanstack/react-query"; @@ -35,7 +34,7 @@ export const getContext = ( * Set this to \`false\` to disable automatic refetching when the query mounts or changes query keys. * Defaults to \`true\`. */ - enabled?: Enabled; + enabled?: UseQueryOptions['enabled']; }; };