@tanstack/vue-query 5.106.1 → 5.107.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/legacy/devtools/devtools.d.cts +1 -1
- package/build/legacy/devtools/devtools.d.ts +1 -1
- package/build/legacy/index.d.cts +4 -4
- package/build/legacy/index.d.ts +4 -4
- package/build/legacy/{infiniteQueryOptions-CkULbee9.d.cts → infiniteQueryOptions-BSwO8rvy.d.cts} +49 -8
- package/build/legacy/infiniteQueryOptions-BSwO8rvy.d.cts.map +1 -0
- package/build/legacy/{infiniteQueryOptions-CGWmFi6_.d.ts → infiniteQueryOptions-Bq8UQFvj.d.ts} +49 -8
- package/build/legacy/infiniteQueryOptions-Bq8UQFvj.d.ts.map +1 -0
- package/build/legacy/infiniteQueryOptions.d.cts +1 -1
- package/build/legacy/infiniteQueryOptions.d.ts +1 -1
- package/build/{modern/queryClient-BGn8uIej.d.cts → legacy/queryClient-BSSPWSvX.d.cts} +2 -2
- package/build/legacy/{queryClient-BGn8uIej.d.cts.map → queryClient-BSSPWSvX.d.cts.map} +1 -1
- package/build/{modern/queryClient-Ba4HSFnn.d.ts → legacy/queryClient-Bgw9hMbf.d.ts} +2 -2
- package/build/legacy/{queryClient-Ba4HSFnn.d.ts.map → queryClient-Bgw9hMbf.d.ts.map} +1 -1
- package/build/legacy/queryClient.d.cts +1 -1
- package/build/legacy/queryClient.d.ts +1 -1
- package/build/{modern/queryOptions-BuZEBLtg.d.cts → legacy/queryOptions-B-eHjgaY.d.cts} +12 -4
- package/build/legacy/queryOptions-B-eHjgaY.d.cts.map +1 -0
- package/build/{modern/queryOptions-dXiBZnGk.d.ts → legacy/queryOptions-D1-foH1W.d.ts} +12 -4
- package/build/legacy/queryOptions-D1-foH1W.d.ts.map +1 -0
- package/build/legacy/queryOptions.cjs.map +1 -1
- package/build/legacy/queryOptions.d.cts +2 -2
- package/build/legacy/queryOptions.d.ts +2 -2
- package/build/legacy/queryOptions.js.map +1 -1
- package/build/legacy/useBaseQuery.cjs +11 -5
- package/build/legacy/useBaseQuery.cjs.map +1 -1
- package/build/legacy/useBaseQuery.d.cts +1 -1
- package/build/legacy/useBaseQuery.d.ts +1 -1
- package/build/legacy/useBaseQuery.js +11 -5
- package/build/legacy/useBaseQuery.js.map +1 -1
- package/build/legacy/useInfiniteQuery.cjs.map +1 -1
- package/build/legacy/useInfiniteQuery.d.cts +2 -2
- package/build/legacy/useInfiniteQuery.d.ts +2 -2
- package/build/legacy/useInfiniteQuery.js.map +1 -1
- package/build/legacy/useIsFetching.d.cts +1 -1
- package/build/legacy/useIsFetching.d.ts +1 -1
- package/build/legacy/useMutation.d.cts +1 -1
- package/build/legacy/useMutation.d.ts +1 -1
- package/build/legacy/useMutationState.d.cts +1 -1
- package/build/legacy/useMutationState.d.ts +1 -1
- package/build/legacy/usePrefetchInfiniteQuery.d.cts +1 -1
- package/build/legacy/usePrefetchInfiniteQuery.d.ts +1 -1
- package/build/legacy/usePrefetchQuery.d.cts +1 -1
- package/build/legacy/usePrefetchQuery.d.ts +1 -1
- package/build/legacy/useQueries.cjs +1 -1
- package/build/legacy/useQueries.cjs.map +1 -1
- package/build/legacy/useQueries.d.cts +2 -2
- package/build/legacy/useQueries.d.ts +2 -2
- package/build/legacy/useQueries.js +1 -1
- package/build/legacy/useQueries.js.map +1 -1
- package/build/legacy/useQuery.cjs.map +1 -1
- package/build/legacy/useQuery.d.cts +25 -4
- package/build/legacy/useQuery.d.cts.map +1 -1
- package/build/legacy/useQuery.d.ts +25 -4
- package/build/legacy/useQuery.d.ts.map +1 -1
- package/build/legacy/useQuery.js.map +1 -1
- package/build/legacy/useQueryClient.d.cts +1 -1
- package/build/legacy/useQueryClient.d.ts +1 -1
- package/build/legacy/vueQueryPlugin.cjs +2 -0
- package/build/legacy/vueQueryPlugin.cjs.map +1 -1
- package/build/legacy/vueQueryPlugin.d.cts +1 -1
- package/build/legacy/vueQueryPlugin.d.ts +1 -1
- package/build/legacy/vueQueryPlugin.js +2 -0
- package/build/legacy/vueQueryPlugin.js.map +1 -1
- package/build/modern/devtools/devtools.d.cts +1 -1
- package/build/modern/devtools/devtools.d.ts +1 -1
- package/build/modern/index.d.cts +4 -4
- package/build/modern/index.d.ts +4 -4
- package/build/modern/{infiniteQueryOptions-CkULbee9.d.cts → infiniteQueryOptions-BSwO8rvy.d.cts} +49 -8
- package/build/modern/infiniteQueryOptions-BSwO8rvy.d.cts.map +1 -0
- package/build/modern/{infiniteQueryOptions-CGWmFi6_.d.ts → infiniteQueryOptions-Bq8UQFvj.d.ts} +49 -8
- package/build/modern/infiniteQueryOptions-Bq8UQFvj.d.ts.map +1 -0
- package/build/modern/infiniteQueryOptions.d.cts +1 -1
- package/build/modern/infiniteQueryOptions.d.ts +1 -1
- package/build/{legacy/queryClient-BGn8uIej.d.cts → modern/queryClient-BSSPWSvX.d.cts} +2 -2
- package/build/modern/{queryClient-BGn8uIej.d.cts.map → queryClient-BSSPWSvX.d.cts.map} +1 -1
- package/build/{legacy/queryClient-Ba4HSFnn.d.ts → modern/queryClient-Bgw9hMbf.d.ts} +2 -2
- package/build/modern/{queryClient-Ba4HSFnn.d.ts.map → queryClient-Bgw9hMbf.d.ts.map} +1 -1
- package/build/modern/queryClient.d.cts +1 -1
- package/build/modern/queryClient.d.ts +1 -1
- package/build/{legacy/queryOptions-BuZEBLtg.d.cts → modern/queryOptions-B-eHjgaY.d.cts} +12 -4
- package/build/modern/queryOptions-B-eHjgaY.d.cts.map +1 -0
- package/build/{legacy/queryOptions-dXiBZnGk.d.ts → modern/queryOptions-D1-foH1W.d.ts} +12 -4
- package/build/modern/queryOptions-D1-foH1W.d.ts.map +1 -0
- package/build/modern/queryOptions.cjs.map +1 -1
- package/build/modern/queryOptions.d.cts +2 -2
- package/build/modern/queryOptions.d.ts +2 -2
- package/build/modern/queryOptions.js.map +1 -1
- package/build/modern/useBaseQuery.cjs +11 -5
- package/build/modern/useBaseQuery.cjs.map +1 -1
- package/build/modern/useBaseQuery.d.cts +1 -1
- package/build/modern/useBaseQuery.d.ts +1 -1
- package/build/modern/useBaseQuery.js +11 -5
- package/build/modern/useBaseQuery.js.map +1 -1
- package/build/modern/useInfiniteQuery.cjs.map +1 -1
- package/build/modern/useInfiniteQuery.d.cts +2 -2
- package/build/modern/useInfiniteQuery.d.ts +2 -2
- package/build/modern/useInfiniteQuery.js.map +1 -1
- package/build/modern/useIsFetching.d.cts +1 -1
- package/build/modern/useIsFetching.d.ts +1 -1
- package/build/modern/useMutation.d.cts +1 -1
- package/build/modern/useMutation.d.ts +1 -1
- package/build/modern/useMutationState.d.cts +1 -1
- package/build/modern/useMutationState.d.ts +1 -1
- package/build/modern/usePrefetchInfiniteQuery.d.cts +1 -1
- package/build/modern/usePrefetchInfiniteQuery.d.ts +1 -1
- package/build/modern/usePrefetchQuery.d.cts +1 -1
- package/build/modern/usePrefetchQuery.d.ts +1 -1
- package/build/modern/useQueries.cjs +1 -1
- package/build/modern/useQueries.cjs.map +1 -1
- package/build/modern/useQueries.d.cts +2 -2
- package/build/modern/useQueries.d.ts +2 -2
- package/build/modern/useQueries.js +1 -1
- package/build/modern/useQueries.js.map +1 -1
- package/build/modern/useQuery.cjs.map +1 -1
- package/build/modern/useQuery.d.cts +25 -4
- package/build/modern/useQuery.d.cts.map +1 -1
- package/build/modern/useQuery.d.ts +25 -4
- package/build/modern/useQuery.d.ts.map +1 -1
- package/build/modern/useQuery.js.map +1 -1
- package/build/modern/useQueryClient.d.cts +1 -1
- package/build/modern/useQueryClient.d.ts +1 -1
- package/build/modern/vueQueryPlugin.cjs +2 -0
- package/build/modern/vueQueryPlugin.cjs.map +1 -1
- package/build/modern/vueQueryPlugin.d.cts +1 -1
- package/build/modern/vueQueryPlugin.d.ts +1 -1
- package/build/modern/vueQueryPlugin.js +2 -0
- package/build/modern/vueQueryPlugin.js.map +1 -1
- package/package.json +2 -2
- package/src/index.ts +2 -0
- package/src/queryOptions.ts +23 -9
- package/src/useBaseQuery.ts +68 -8
- package/src/useInfiniteQuery.ts +19 -9
- package/src/useQueries.ts +7 -2
- package/src/useQuery.ts +22 -1
- package/src/vueQueryPlugin.ts +13 -6
- package/build/legacy/infiniteQueryOptions-CGWmFi6_.d.ts.map +0 -1
- package/build/legacy/infiniteQueryOptions-CkULbee9.d.cts.map +0 -1
- package/build/legacy/queryOptions-BuZEBLtg.d.cts.map +0 -1
- package/build/legacy/queryOptions-dXiBZnGk.d.ts.map +0 -1
- package/build/modern/infiniteQueryOptions-CGWmFi6_.d.ts.map +0 -1
- package/build/modern/infiniteQueryOptions-CkULbee9.d.cts.map +0 -1
- package/build/modern/queryOptions-BuZEBLtg.d.cts.map +0 -1
- package/build/modern/queryOptions-dXiBZnGk.d.ts.map +0 -1
package/build/legacy/index.d.cts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { c as MutationOptions } from "./types-u_Tu5Ybs.cjs";
|
|
2
|
-
import { a as UndefinedInitialQueryOptionsWithDataTag, i as UndefinedInitialQueryOptions, n as DefinedInitialQueryOptionsWithDataTag, o as UseQueryOptions, r as QueryOptions, s as
|
|
3
|
-
import { t as QueryClient } from "./queryClient-
|
|
2
|
+
import { a as UndefinedInitialQueryOptionsWithDataTag, c as queryOptions, i as UndefinedInitialQueryOptions, n as DefinedInitialQueryOptionsWithDataTag, o as UseQueryOptions, r as QueryOptions, s as VueQueryEnabledOption, t as DefinedInitialQueryOptions } from "./queryOptions-B-eHjgaY.cjs";
|
|
3
|
+
import { t as QueryClient } from "./queryClient-BSSPWSvX.cjs";
|
|
4
4
|
import { useQueryClient } from "./useQueryClient.cjs";
|
|
5
5
|
import { VueQueryPlugin, VueQueryPluginOptions } from "./vueQueryPlugin.cjs";
|
|
6
6
|
import { QueryCache } from "./queryCache.cjs";
|
|
7
|
-
import { a as
|
|
7
|
+
import { a as UseInfiniteQueryOptions, i as UseInfiniteQueryDefinedReturnType, n as UndefinedInitialDataInfiniteOptions, o as UseInfiniteQueryReturnType, r as infiniteQueryOptions, s as useInfiniteQuery, t as DefinedInitialDataInfiniteOptions } from "./infiniteQueryOptions-BSwO8rvy.cjs";
|
|
8
8
|
import { MutationCache } from "./mutationCache.cjs";
|
|
9
9
|
import { mutationOptions } from "./mutationOptions.cjs";
|
|
10
10
|
import { UseQueryDefinedReturnType, UseQueryReturnType, useQuery } from "./useQuery.cjs";
|
|
@@ -16,4 +16,4 @@ import { UseIsFetchingFilters, useIsFetching } from "./useIsFetching.cjs";
|
|
|
16
16
|
import { MutationStateOptions, UseIsMutatingFilters, useIsMutating, useMutationState } from "./useMutationState.cjs";
|
|
17
17
|
import { VUE_QUERY_CLIENT } from "./utils.cjs";
|
|
18
18
|
export * from "@tanstack/query-core";
|
|
19
|
-
export { type DefinedInitialDataInfiniteOptions, type DefinedInitialQueryOptions, type DefinedInitialQueryOptionsWithDataTag, MutationCache, type MutationOptions, type MutationResult, type MutationStateOptions, QueryCache, QueryClient, type QueryOptions, type UndefinedInitialDataInfiniteOptions, type UndefinedInitialQueryOptions, type UndefinedInitialQueryOptionsWithDataTag, type UseInfiniteQueryOptions, type UseInfiniteQueryReturnType, type UseIsFetchingFilters, type UseIsMutatingFilters, type UseMutationOptions, type UseMutationReturnType, type UsePrefetchInfiniteQueryOptions, type UsePrefetchQueryOptions, type UseQueriesOptions, type UseQueriesResults, type UseQueryDefinedReturnType, type UseQueryOptions, type UseQueryReturnType, VUE_QUERY_CLIENT, VueQueryPlugin, type VueQueryPluginOptions, infiniteQueryOptions, mutationOptions, queryOptions, useInfiniteQuery, useIsFetching, useIsMutating, useMutation, useMutationState, usePrefetchInfiniteQuery, usePrefetchQuery, useQueries, useQuery, useQueryClient };
|
|
19
|
+
export { type DefinedInitialDataInfiniteOptions, type DefinedInitialQueryOptions, type DefinedInitialQueryOptionsWithDataTag, MutationCache, type MutationOptions, type MutationResult, type MutationStateOptions, QueryCache, QueryClient, type QueryOptions, type UndefinedInitialDataInfiniteOptions, type UndefinedInitialQueryOptions, type UndefinedInitialQueryOptionsWithDataTag, type UseInfiniteQueryDefinedReturnType, type UseInfiniteQueryOptions, type UseInfiniteQueryReturnType, type UseIsFetchingFilters, type UseIsMutatingFilters, type UseMutationOptions, type UseMutationReturnType, type UsePrefetchInfiniteQueryOptions, type UsePrefetchQueryOptions, type UseQueriesOptions, type UseQueriesResults, type UseQueryDefinedReturnType, type UseQueryOptions, type UseQueryReturnType, VUE_QUERY_CLIENT, type VueQueryEnabledOption, VueQueryPlugin, type VueQueryPluginOptions, infiniteQueryOptions, mutationOptions, queryOptions, useInfiniteQuery, useIsFetching, useIsMutating, useMutation, useMutationState, usePrefetchInfiniteQuery, usePrefetchQuery, useQueries, useQuery, useQueryClient };
|
package/build/legacy/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { c as MutationOptions } from "./types-u_Tu5Ybs.js";
|
|
2
|
-
import { a as UndefinedInitialQueryOptionsWithDataTag, i as UndefinedInitialQueryOptions, n as DefinedInitialQueryOptionsWithDataTag, o as UseQueryOptions, r as QueryOptions, s as
|
|
3
|
-
import { t as QueryClient } from "./queryClient-
|
|
2
|
+
import { a as UndefinedInitialQueryOptionsWithDataTag, c as queryOptions, i as UndefinedInitialQueryOptions, n as DefinedInitialQueryOptionsWithDataTag, o as UseQueryOptions, r as QueryOptions, s as VueQueryEnabledOption, t as DefinedInitialQueryOptions } from "./queryOptions-D1-foH1W.js";
|
|
3
|
+
import { t as QueryClient } from "./queryClient-Bgw9hMbf.js";
|
|
4
4
|
import { useQueryClient } from "./useQueryClient.js";
|
|
5
5
|
import { VueQueryPlugin, VueQueryPluginOptions } from "./vueQueryPlugin.js";
|
|
6
6
|
import { QueryCache } from "./queryCache.js";
|
|
7
|
-
import { a as
|
|
7
|
+
import { a as UseInfiniteQueryOptions, i as UseInfiniteQueryDefinedReturnType, n as UndefinedInitialDataInfiniteOptions, o as UseInfiniteQueryReturnType, r as infiniteQueryOptions, s as useInfiniteQuery, t as DefinedInitialDataInfiniteOptions } from "./infiniteQueryOptions-Bq8UQFvj.js";
|
|
8
8
|
import { MutationCache } from "./mutationCache.js";
|
|
9
9
|
import { mutationOptions } from "./mutationOptions.js";
|
|
10
10
|
import { UseQueryDefinedReturnType, UseQueryReturnType, useQuery } from "./useQuery.js";
|
|
@@ -16,4 +16,4 @@ import { UseIsFetchingFilters, useIsFetching } from "./useIsFetching.js";
|
|
|
16
16
|
import { MutationStateOptions, UseIsMutatingFilters, useIsMutating, useMutationState } from "./useMutationState.js";
|
|
17
17
|
import { VUE_QUERY_CLIENT } from "./utils.js";
|
|
18
18
|
export * from "@tanstack/query-core";
|
|
19
|
-
export { type DefinedInitialDataInfiniteOptions, type DefinedInitialQueryOptions, type DefinedInitialQueryOptionsWithDataTag, MutationCache, type MutationOptions, type MutationResult, type MutationStateOptions, QueryCache, QueryClient, type QueryOptions, type UndefinedInitialDataInfiniteOptions, type UndefinedInitialQueryOptions, type UndefinedInitialQueryOptionsWithDataTag, type UseInfiniteQueryOptions, type UseInfiniteQueryReturnType, type UseIsFetchingFilters, type UseIsMutatingFilters, type UseMutationOptions, type UseMutationReturnType, type UsePrefetchInfiniteQueryOptions, type UsePrefetchQueryOptions, type UseQueriesOptions, type UseQueriesResults, type UseQueryDefinedReturnType, type UseQueryOptions, type UseQueryReturnType, VUE_QUERY_CLIENT, VueQueryPlugin, type VueQueryPluginOptions, infiniteQueryOptions, mutationOptions, queryOptions, useInfiniteQuery, useIsFetching, useIsMutating, useMutation, useMutationState, usePrefetchInfiniteQuery, usePrefetchQuery, useQueries, useQuery, useQueryClient };
|
|
19
|
+
export { type DefinedInitialDataInfiniteOptions, type DefinedInitialQueryOptions, type DefinedInitialQueryOptionsWithDataTag, MutationCache, type MutationOptions, type MutationResult, type MutationStateOptions, QueryCache, QueryClient, type QueryOptions, type UndefinedInitialDataInfiniteOptions, type UndefinedInitialQueryOptions, type UndefinedInitialQueryOptionsWithDataTag, type UseInfiniteQueryDefinedReturnType, type UseInfiniteQueryOptions, type UseInfiniteQueryReturnType, type UseIsFetchingFilters, type UseIsMutatingFilters, type UseMutationOptions, type UseMutationReturnType, type UsePrefetchInfiniteQueryOptions, type UsePrefetchQueryOptions, type UseQueriesOptions, type UseQueriesResults, type UseQueryDefinedReturnType, type UseQueryOptions, type UseQueryReturnType, VUE_QUERY_CLIENT, type VueQueryEnabledOption, VueQueryPlugin, type VueQueryPluginOptions, infiniteQueryOptions, mutationOptions, queryOptions, useInfiniteQuery, useIsFetching, useIsMutating, useMutation, useMutationState, usePrefetchInfiniteQuery, usePrefetchQuery, useQueries, useQuery, useQueryClient };
|
package/build/legacy/{infiniteQueryOptions-CkULbee9.d.cts → infiniteQueryOptions-BSwO8rvy.d.cts}
RENAMED
|
@@ -1,11 +1,16 @@
|
|
|
1
1
|
import { a as MaybeRef, d as ShallowOption, o as MaybeRefDeep, s as MaybeRefOrGetter, t as DeepUnwrapRef } from "./types-u_Tu5Ybs.cjs";
|
|
2
|
-
import { o as UseQueryOptions } from "./queryOptions-
|
|
3
|
-
import { t as QueryClient$1 } from "./queryClient-
|
|
4
|
-
import { DefaultError, InfiniteData, InfiniteQueryObserverOptions, InfiniteQueryObserverResult, InitialDataFunction, NonUndefinedGuard, QueryKey, QueryKeyWithDataTag, QueryObserver, QueryObserverResult } from "@tanstack/query-core";
|
|
2
|
+
import { o as UseQueryOptions, s as VueQueryEnabledOption } from "./queryOptions-B-eHjgaY.cjs";
|
|
3
|
+
import { t as QueryClient$1 } from "./queryClient-BSSPWSvX.cjs";
|
|
4
|
+
import { DefaultError, DefinedInfiniteQueryObserverResult, InfiniteData, InfiniteQueryObserverOptions, InfiniteQueryObserverResult, InitialDataFunction, NonUndefinedGuard, QueryKey, QueryKeyWithDataTag, QueryObserver, QueryObserverResult } from "@tanstack/query-core";
|
|
5
5
|
import { Ref } from "vue-demi";
|
|
6
|
+
/**
|
|
7
|
+
* Readonly view of a union that stays a union. A single `Readonly<Union>` collapses the members, which
|
|
8
|
+
* drops the `status` / `isSuccess` / `isPending` discriminants.
|
|
9
|
+
*/
|
|
10
|
+
type ReadonlyQueryState<T> = T extends any ? { readonly [K in keyof T]: T[K]; } : never;
|
|
6
11
|
/**
|
|
7
12
|
* The result of the query composables: every property of the observer result wrapped in a `Ref`, except
|
|
8
|
-
* the `refetch`, `fetchNextPage`, and `fetchPreviousPage` functions, plus `suspense`.
|
|
13
|
+
* the `refetch`, `fetchNextPage`, and `fetchPreviousPage` functions, plus `suspense` and `state`.
|
|
9
14
|
*/
|
|
10
15
|
type UseBaseQueryReturnType<TData, TError, TResult = QueryObserverResult<TData, TError>> = { [K in keyof TResult]: K extends 'fetchNextPage' | 'fetchPreviousPage' | 'refetch' ? TResult[K] : Ref<Readonly<TResult>[K]>; } & {
|
|
11
16
|
/**
|
|
@@ -17,6 +22,37 @@ type UseBaseQueryReturnType<TData, TError, TResult = QueryObserverResult<TData,
|
|
|
17
22
|
* `true`, in which case it rejects.
|
|
18
23
|
*/
|
|
19
24
|
suspense: () => Promise<TResult>;
|
|
25
|
+
/**
|
|
26
|
+
* The query result as one readonly reactive object. `data`, `error`, `status`, `isPending`, and the other
|
|
27
|
+
* fields are plain values — read `state.data`, not `state.data.value`.
|
|
28
|
+
*
|
|
29
|
+
* The object is a discriminated union, so a check on `status`, `isSuccess`, `isPending`, or `isError`
|
|
30
|
+
* narrows the other fields. When `status` is `'success'` (or `isSuccess` is `true`), `data` is `TData`.
|
|
31
|
+
* When `status` is `'pending'` (or `isPending` is `true`), `data` is `undefined` and `error` is `null`.
|
|
32
|
+
* @example
|
|
33
|
+
* ```vue
|
|
34
|
+
* <script setup lang="ts">
|
|
35
|
+
* import { useQuery } from '@tanstack/vue-query'
|
|
36
|
+
*
|
|
37
|
+
* const { state } = useQuery({
|
|
38
|
+
* queryKey: ['post'],
|
|
39
|
+
* queryFn: fetchPost,
|
|
40
|
+
* })
|
|
41
|
+
*
|
|
42
|
+
* if (state.status === 'success') {
|
|
43
|
+
* // `state.data` is `Post`, not `Post | undefined`
|
|
44
|
+
* console.log(state.data.title)
|
|
45
|
+
* }
|
|
46
|
+
* </script>
|
|
47
|
+
*
|
|
48
|
+
* <template>
|
|
49
|
+
* <span v-if="state.status === 'pending'">Loading...</span>
|
|
50
|
+
* <span v-else-if="state.status === 'error'">Error: {{ state.error.message }}</span>
|
|
51
|
+
* <h1 v-else>{{ state.data.title }}</h1>
|
|
52
|
+
* </template>
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
state: ReadonlyQueryState<TResult>;
|
|
20
56
|
};
|
|
21
57
|
type UseQueryOptionsGeneric<TQueryFnData, TError, TData, TQueryData, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown> = UseQueryOptions<TQueryFnData, TError, TData, TQueryData, TQueryKey> | UseInfiniteQueryOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>;
|
|
22
58
|
/**
|
|
@@ -33,12 +69,17 @@ declare function useBaseQuery<TQueryFnData, TError, TData, TQueryData, TQueryKey
|
|
|
33
69
|
* `@tanstack/query-core`, plus the `shallow` option. Each option except `shallow` can also be a `ref` (and
|
|
34
70
|
* `enabled` a reactive getter).
|
|
35
71
|
*/
|
|
36
|
-
type UseInfiniteQueryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown> = MaybeRef<{ [Property in keyof InfiniteQueryObserverOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>]: Property extends 'enabled' ?
|
|
72
|
+
type UseInfiniteQueryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown> = MaybeRef<{ [Property in keyof InfiniteQueryObserverOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>]: Property extends 'enabled' ? VueQueryEnabledOption<TQueryFnData, TError, InfiniteData<TQueryFnData, TPageParam>, DeepUnwrapRef<TQueryKey>> : MaybeRefDeep<InfiniteQueryObserverOptions<TQueryFnData, TError, TData, DeepUnwrapRef<TQueryKey>, TPageParam>[Property]>; } & ShallowOption>;
|
|
37
73
|
/**
|
|
38
74
|
* The result of `useInfiniteQuery`: {@link InfiniteQueryObserverResult} from `@tanstack/query-core`, with
|
|
39
75
|
* its properties wrapped in `Ref`s as in {@link UseBaseQueryReturnType}.
|
|
40
76
|
*/
|
|
41
77
|
type UseInfiniteQueryReturnType<TData, TError> = UseBaseQueryReturnType<TData, TError, InfiniteQueryObserverResult<TData, TError>>;
|
|
78
|
+
/**
|
|
79
|
+
* The result of `useInfiniteQuery` when `initialData` is set — `data` is never `undefined` (unless a `select`
|
|
80
|
+
* changes `TData` to include `undefined`).
|
|
81
|
+
*/
|
|
82
|
+
type UseInfiniteQueryDefinedReturnType<TData, TError> = UseBaseQueryReturnType<TData, TError, DefinedInfiniteQueryObserverResult<TData, TError>>;
|
|
42
83
|
/**
|
|
43
84
|
* The options for `useInfiniteQuery` are identical to `useQuery`, with the addition of
|
|
44
85
|
* `initialPageParam`, `getNextPageParam`, `getPreviousPageParam`, and `maxPages`.
|
|
@@ -86,7 +127,7 @@ type UseInfiniteQueryReturnType<TData, TError> = UseBaseQueryReturnType<TData, T
|
|
|
86
127
|
* </template>
|
|
87
128
|
* ```
|
|
88
129
|
*/
|
|
89
|
-
declare function useInfiniteQuery<TQueryFnData, TError = DefaultError, TData = InfiniteData<TQueryFnData>, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown>(options: MaybeRefOrGetter<DefinedInitialDataInfiniteOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>>, queryClient?: QueryClient$1):
|
|
130
|
+
declare function useInfiniteQuery<TQueryFnData, TError = DefaultError, TData = InfiniteData<TQueryFnData>, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown>(options: MaybeRefOrGetter<DefinedInitialDataInfiniteOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>>, queryClient?: QueryClient$1): UseInfiniteQueryDefinedReturnType<TData, TError>;
|
|
90
131
|
/**
|
|
91
132
|
* The options for `useInfiniteQuery` are identical to `useQuery`, with the addition of
|
|
92
133
|
* `initialPageParam`, `getNextPageParam`, `getPreviousPageParam`, and `maxPages`.
|
|
@@ -365,5 +406,5 @@ declare function infiniteQueryOptions<TQueryFnData, TError = DefaultError, TData
|
|
|
365
406
|
* ```
|
|
366
407
|
*/
|
|
367
408
|
declare function infiniteQueryOptions<TQueryFnData, TError = DefaultError, TData = InfiniteData<TQueryFnData>, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown>(options: UndefinedInitialDataInfiniteOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>): UndefinedInitialDataInfiniteOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam> & QueryKeyWithDataTag<TQueryKey, InfiniteData<TQueryFnData>, TError>;
|
|
368
|
-
export {
|
|
369
|
-
//# sourceMappingURL=infiniteQueryOptions-
|
|
409
|
+
export { UseInfiniteQueryOptions as a, UseBaseQueryReturnType as c, UseInfiniteQueryDefinedReturnType as i, useBaseQuery as l, UndefinedInitialDataInfiniteOptions as n, UseInfiniteQueryReturnType as o, infiniteQueryOptions as r, useInfiniteQuery as s, DefinedInitialDataInfiniteOptions as t };
|
|
410
|
+
//# sourceMappingURL=infiniteQueryOptions-BSwO8rvy.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"infiniteQueryOptions-BSwO8rvy.d.cts","names":["QueryClient","QueryClient"],"sources":["../../src/useBaseQuery.ts","../../src/useInfiniteQuery.ts","../../src/infiniteQueryOptions.ts"],"mappings":";;;;;;;;;KA8BK,mBAAmB,KAAK,4BACb,WAAW,IAAI,EAAE;;;;;KAOrB,uBACV,OACA,QACA,UAAU,oBAAoB,OAAO,cAEpC,WAAW,UAAU,8DAIlB,QAAQ,KACR,IAAI,SAAS,SAAS;;;;;;;;;EAU1B,gBAAgB,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+BxB,OAAO,mBAAmB;;KAGvB,uBACH,cACA,QACA,OACA,YACA,kBAAkB,WAAW,UAC7B,wBAEE,gB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AEA,SAAS,iBACP,wBAAwB,cAAc,QAAQ,OAAO,WAAW,cAElE,cAAcA,gBACb,2BAA2B,OAAO;;;;;;;;;;;;KC9VzB,oCACV,cACA,SAAS,cACT,QAAQ,aAAa,eACrB,kBAAkB,WAAW,UAC7B,wBACE,wBACF,cACA,QACA,OACA,WACA;EAEA,0BAEI,kBAAkB,aAAa,cAAc,eAC7C,oBACE,kBAAkB,aAAa,cAAc;;;;;;;;;;;;KAczC,kCACV,cACA,SAAS,cACT,QAAQ,aAAa,eACrB,kBAAkB,WAAW,UAC7B,wBACE,wBACF,cACA,QACA,OACA,WACA;;;;;;;;EASA,aACI,kBAAkB,aAAa,cAAc,sBACtC,kBAAkB,aAAa,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAiC1C,qBACd,cACA,SAAS,cACT,QAAQ,aAAa,eACrB,kBAAkB,WAAW,UAC7B,sBAEA,SAAS,kCACP,cACA,QACA,OACA,WACA,cAED,kCACD,cACA,QACA,OACA,WACA,cAEA,oBAAoB,WAAW,aAAa,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;iBA0B7C,qBACd,cACA,SAAS,cACT,QAAQ,aAAa,eACrB,kBAAkB,WAAW,UAC7B,sBAEA,SAAS,oCACP,cACA,QACA,OACA,WACA,cAED,oCACD,cACA,QACA,OACA,WACA,cAEA,oBAAoB,WAAW,aAAa,eAAe"}
|
package/build/legacy/{infiniteQueryOptions-CGWmFi6_.d.ts → infiniteQueryOptions-Bq8UQFvj.d.ts}
RENAMED
|
@@ -1,11 +1,16 @@
|
|
|
1
1
|
import { a as MaybeRef, d as ShallowOption, o as MaybeRefDeep, s as MaybeRefOrGetter, t as DeepUnwrapRef } from "./types-u_Tu5Ybs.js";
|
|
2
|
-
import { o as UseQueryOptions } from "./queryOptions-
|
|
3
|
-
import { t as QueryClient$1 } from "./queryClient-
|
|
4
|
-
import { DefaultError, InfiniteData, InfiniteQueryObserverOptions, InfiniteQueryObserverResult, InitialDataFunction, NonUndefinedGuard, QueryKey, QueryKeyWithDataTag, QueryObserver, QueryObserverResult } from "@tanstack/query-core";
|
|
2
|
+
import { o as UseQueryOptions, s as VueQueryEnabledOption } from "./queryOptions-D1-foH1W.js";
|
|
3
|
+
import { t as QueryClient$1 } from "./queryClient-Bgw9hMbf.js";
|
|
4
|
+
import { DefaultError, DefinedInfiniteQueryObserverResult, InfiniteData, InfiniteQueryObserverOptions, InfiniteQueryObserverResult, InitialDataFunction, NonUndefinedGuard, QueryKey, QueryKeyWithDataTag, QueryObserver, QueryObserverResult } from "@tanstack/query-core";
|
|
5
5
|
import { Ref } from "vue-demi";
|
|
6
|
+
/**
|
|
7
|
+
* Readonly view of a union that stays a union. A single `Readonly<Union>` collapses the members, which
|
|
8
|
+
* drops the `status` / `isSuccess` / `isPending` discriminants.
|
|
9
|
+
*/
|
|
10
|
+
type ReadonlyQueryState<T> = T extends any ? { readonly [K in keyof T]: T[K]; } : never;
|
|
6
11
|
/**
|
|
7
12
|
* The result of the query composables: every property of the observer result wrapped in a `Ref`, except
|
|
8
|
-
* the `refetch`, `fetchNextPage`, and `fetchPreviousPage` functions, plus `suspense`.
|
|
13
|
+
* the `refetch`, `fetchNextPage`, and `fetchPreviousPage` functions, plus `suspense` and `state`.
|
|
9
14
|
*/
|
|
10
15
|
type UseBaseQueryReturnType<TData, TError, TResult = QueryObserverResult<TData, TError>> = { [K in keyof TResult]: K extends 'fetchNextPage' | 'fetchPreviousPage' | 'refetch' ? TResult[K] : Ref<Readonly<TResult>[K]>; } & {
|
|
11
16
|
/**
|
|
@@ -17,6 +22,37 @@ type UseBaseQueryReturnType<TData, TError, TResult = QueryObserverResult<TData,
|
|
|
17
22
|
* `true`, in which case it rejects.
|
|
18
23
|
*/
|
|
19
24
|
suspense: () => Promise<TResult>;
|
|
25
|
+
/**
|
|
26
|
+
* The query result as one readonly reactive object. `data`, `error`, `status`, `isPending`, and the other
|
|
27
|
+
* fields are plain values — read `state.data`, not `state.data.value`.
|
|
28
|
+
*
|
|
29
|
+
* The object is a discriminated union, so a check on `status`, `isSuccess`, `isPending`, or `isError`
|
|
30
|
+
* narrows the other fields. When `status` is `'success'` (or `isSuccess` is `true`), `data` is `TData`.
|
|
31
|
+
* When `status` is `'pending'` (or `isPending` is `true`), `data` is `undefined` and `error` is `null`.
|
|
32
|
+
* @example
|
|
33
|
+
* ```vue
|
|
34
|
+
* <script setup lang="ts">
|
|
35
|
+
* import { useQuery } from '@tanstack/vue-query'
|
|
36
|
+
*
|
|
37
|
+
* const { state } = useQuery({
|
|
38
|
+
* queryKey: ['post'],
|
|
39
|
+
* queryFn: fetchPost,
|
|
40
|
+
* })
|
|
41
|
+
*
|
|
42
|
+
* if (state.status === 'success') {
|
|
43
|
+
* // `state.data` is `Post`, not `Post | undefined`
|
|
44
|
+
* console.log(state.data.title)
|
|
45
|
+
* }
|
|
46
|
+
* </script>
|
|
47
|
+
*
|
|
48
|
+
* <template>
|
|
49
|
+
* <span v-if="state.status === 'pending'">Loading...</span>
|
|
50
|
+
* <span v-else-if="state.status === 'error'">Error: {{ state.error.message }}</span>
|
|
51
|
+
* <h1 v-else>{{ state.data.title }}</h1>
|
|
52
|
+
* </template>
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
state: ReadonlyQueryState<TResult>;
|
|
20
56
|
};
|
|
21
57
|
type UseQueryOptionsGeneric<TQueryFnData, TError, TData, TQueryData, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown> = UseQueryOptions<TQueryFnData, TError, TData, TQueryData, TQueryKey> | UseInfiniteQueryOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>;
|
|
22
58
|
/**
|
|
@@ -33,12 +69,17 @@ declare function useBaseQuery<TQueryFnData, TError, TData, TQueryData, TQueryKey
|
|
|
33
69
|
* `@tanstack/query-core`, plus the `shallow` option. Each option except `shallow` can also be a `ref` (and
|
|
34
70
|
* `enabled` a reactive getter).
|
|
35
71
|
*/
|
|
36
|
-
type UseInfiniteQueryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown> = MaybeRef<{ [Property in keyof InfiniteQueryObserverOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>]: Property extends 'enabled' ?
|
|
72
|
+
type UseInfiniteQueryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown> = MaybeRef<{ [Property in keyof InfiniteQueryObserverOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>]: Property extends 'enabled' ? VueQueryEnabledOption<TQueryFnData, TError, InfiniteData<TQueryFnData, TPageParam>, DeepUnwrapRef<TQueryKey>> : MaybeRefDeep<InfiniteQueryObserverOptions<TQueryFnData, TError, TData, DeepUnwrapRef<TQueryKey>, TPageParam>[Property]>; } & ShallowOption>;
|
|
37
73
|
/**
|
|
38
74
|
* The result of `useInfiniteQuery`: {@link InfiniteQueryObserverResult} from `@tanstack/query-core`, with
|
|
39
75
|
* its properties wrapped in `Ref`s as in {@link UseBaseQueryReturnType}.
|
|
40
76
|
*/
|
|
41
77
|
type UseInfiniteQueryReturnType<TData, TError> = UseBaseQueryReturnType<TData, TError, InfiniteQueryObserverResult<TData, TError>>;
|
|
78
|
+
/**
|
|
79
|
+
* The result of `useInfiniteQuery` when `initialData` is set — `data` is never `undefined` (unless a `select`
|
|
80
|
+
* changes `TData` to include `undefined`).
|
|
81
|
+
*/
|
|
82
|
+
type UseInfiniteQueryDefinedReturnType<TData, TError> = UseBaseQueryReturnType<TData, TError, DefinedInfiniteQueryObserverResult<TData, TError>>;
|
|
42
83
|
/**
|
|
43
84
|
* The options for `useInfiniteQuery` are identical to `useQuery`, with the addition of
|
|
44
85
|
* `initialPageParam`, `getNextPageParam`, `getPreviousPageParam`, and `maxPages`.
|
|
@@ -86,7 +127,7 @@ type UseInfiniteQueryReturnType<TData, TError> = UseBaseQueryReturnType<TData, T
|
|
|
86
127
|
* </template>
|
|
87
128
|
* ```
|
|
88
129
|
*/
|
|
89
|
-
declare function useInfiniteQuery<TQueryFnData, TError = DefaultError, TData = InfiniteData<TQueryFnData>, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown>(options: MaybeRefOrGetter<DefinedInitialDataInfiniteOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>>, queryClient?: QueryClient$1):
|
|
130
|
+
declare function useInfiniteQuery<TQueryFnData, TError = DefaultError, TData = InfiniteData<TQueryFnData>, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown>(options: MaybeRefOrGetter<DefinedInitialDataInfiniteOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>>, queryClient?: QueryClient$1): UseInfiniteQueryDefinedReturnType<TData, TError>;
|
|
90
131
|
/**
|
|
91
132
|
* The options for `useInfiniteQuery` are identical to `useQuery`, with the addition of
|
|
92
133
|
* `initialPageParam`, `getNextPageParam`, `getPreviousPageParam`, and `maxPages`.
|
|
@@ -365,5 +406,5 @@ declare function infiniteQueryOptions<TQueryFnData, TError = DefaultError, TData
|
|
|
365
406
|
* ```
|
|
366
407
|
*/
|
|
367
408
|
declare function infiniteQueryOptions<TQueryFnData, TError = DefaultError, TData = InfiniteData<TQueryFnData>, TQueryKey extends QueryKey = QueryKey, TPageParam = unknown>(options: UndefinedInitialDataInfiniteOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam>): UndefinedInitialDataInfiniteOptions<TQueryFnData, TError, TData, TQueryKey, TPageParam> & QueryKeyWithDataTag<TQueryKey, InfiniteData<TQueryFnData>, TError>;
|
|
368
|
-
export {
|
|
369
|
-
//# sourceMappingURL=infiniteQueryOptions-
|
|
409
|
+
export { UseInfiniteQueryOptions as a, UseBaseQueryReturnType as c, UseInfiniteQueryDefinedReturnType as i, useBaseQuery as l, UndefinedInitialDataInfiniteOptions as n, UseInfiniteQueryReturnType as o, infiniteQueryOptions as r, useInfiniteQuery as s, DefinedInitialDataInfiniteOptions as t };
|
|
410
|
+
//# sourceMappingURL=infiniteQueryOptions-Bq8UQFvj.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"infiniteQueryOptions-Bq8UQFvj.d.ts","names":["QueryClient","QueryClient"],"sources":["../../src/useBaseQuery.ts","../../src/useInfiniteQuery.ts","../../src/infiniteQueryOptions.ts"],"mappings":";;;;;;;;;KA8BK,mBAAmB,KAAK,4BACb,WAAW,IAAI,EAAE;;;;;KAOrB,uBACV,OACA,QACA,UAAU,oBAAoB,OAAO,cAEpC,WAAW,UAAU,8DAIlB,QAAQ,KACR,IAAI,SAAS,SAAS;;;;;;;;;EAU1B,gBAAgB,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+BxB,OAAO,mBAAmB;;KAGvB,uBACH,cACA,QACA,OACA,YACA,kBAAkB,WAAW,UAC7B,wBAEE,gBAAgB,cAAc,QAAQ,OAAO,YAAY,aACzD,wBAAwB,cAAc,QAAQ,OAAO,WAAW;;;;;;;;;iBAUpD,aACd,cACA,QACA,OACA,YACA,kBAAkB,UAClB,YAEA,iBAAiB,eACjB,SAAS,iBACP,uBACE,cACA,QACA,OACA,YACA,WACA,cAGJ,cAAcA,gBACb,uBAAuB,OAAO;;;;;;KClGrB,wBACV,wBACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,UAC7B,wBACE,YAGE,kBAAkB,6BAChB,cACA,QACA,OACA,WACA,cAED,6BACC,sBACE,cACA,QACA,aAAa,cAAc,aAC3B,cAAc,cAEhB,aACE,6BACE,cACA,QACA,OACA,cAAc,YACd,YACA,gBAEN;;;;;KAOM,2BAA2B,OAAO,UAAU,uBACtD,OACA,QACA,4BAA4B,OAAO;;;;;KAOzB,kCAAkC,OAAO,UACnD,uBACE,OACA,QACA,mCAAmC,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAkD9B,iBACd,cACA,SAAS,cACT,QAAQ,aAAa,eACrB,kBAAkB,WAAW,UAC7B,sBAEA,SAAS,iB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AAQ,aAAa,eACrB,kBAAkB,WAAW,UAC7B,sBAEA,SAAS,oCACP,cACA,QACA,OACA,WACA,cAED,oCACD,cACA,QACA,OACA,WACA,cAEA,oBAAoB,WAAW,aAAa,eAAe"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as UndefinedInitialDataInfiniteOptions, r as infiniteQueryOptions, t as DefinedInitialDataInfiniteOptions } from "./infiniteQueryOptions-
|
|
1
|
+
import { n as UndefinedInitialDataInfiniteOptions, r as infiniteQueryOptions, t as DefinedInitialDataInfiniteOptions } from "./infiniteQueryOptions-BSwO8rvy.cjs";
|
|
2
2
|
export { DefinedInitialDataInfiniteOptions, UndefinedInitialDataInfiniteOptions, infiniteQueryOptions };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as UndefinedInitialDataInfiniteOptions, r as infiniteQueryOptions, t as DefinedInitialDataInfiniteOptions } from "./infiniteQueryOptions-
|
|
1
|
+
import { n as UndefinedInitialDataInfiniteOptions, r as infiniteQueryOptions, t as DefinedInitialDataInfiniteOptions } from "./infiniteQueryOptions-Bq8UQFvj.js";
|
|
2
2
|
export { DefinedInitialDataInfiniteOptions, UndefinedInitialDataInfiniteOptions, infiniteQueryOptions };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as MaybeRef, l as NoUnknown, o as MaybeRefDeep, s as MaybeRefOrGetter, u as QueryClientConfig } from "./types-u_Tu5Ybs.cjs";
|
|
2
|
-
import { o as UseQueryOptions } from "./queryOptions-
|
|
2
|
+
import { o as UseQueryOptions } from "./queryOptions-B-eHjgaY.cjs";
|
|
3
3
|
import { CancelOptions, DefaultError, DefaultOptions, EnsureQueryDataOptions, FetchInfiniteQueryOptions, FetchQueryOptions, InferDataFromTag, InferErrorFromTag, InfiniteData, InfiniteQueryExecuteOptions, InvalidateOptions, InvalidateQueryFilters, MutationFilters, MutationKey, MutationObserverOptions, OmitKeyof, QueryClient, QueryExecuteOptions, QueryFilters, QueryKey, QueryObserverOptions, QueryState, RefetchOptions, RefetchQueryFilters, ResetOptions, SetDataOptions, Updater } from "@tanstack/query-core";
|
|
4
4
|
import { Ref } from "vue-demi";
|
|
5
5
|
type VueQueryExecutionOptions<TOptions extends {
|
|
@@ -128,4 +128,4 @@ declare class QueryClient$1 extends QueryClient {
|
|
|
128
128
|
getMutationDefaults(mutationKey: MaybeRefDeep<MutationKey>): MutationObserverOptions<any, any, any, any>;
|
|
129
129
|
}
|
|
130
130
|
export { QueryClient$1 as t };
|
|
131
|
-
//# sourceMappingURL=queryClient-
|
|
131
|
+
//# sourceMappingURL=queryClient-BSSPWSvX.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"queryClient-
|
|
1
|
+
{"version":3,"file":"queryClient-BSSPWSvX.d.cts","names":["QueryClient","QC"],"sources":["../../src/queryClient.ts"],"mappings":";;;;KA2CK,yBAAyB;EAAmB;KAC/C,YACG,kBAAkB,WAAW,6BAC1B,aAAa,SAAS,sBACtB,8BACE,iBAAiB,aAAa,SAAS,cACvC,aAAa,SAAS;;;;;;;;;;;;;;;cAiBnBA,sBAAoBC;EACnB,YAAA,SAAQ;;;;;EAapB,cAAc;EAEL,WACP,UAAS,aAAa,KAAK;EAKpB,WACP,UAAS,aAAa,KAAK;EAKpB,aACP,iBACA,wBAAwB,WAAW,UAEnC,UAAU,kBACT,iBAAiB,OAAO;;EAElB,aAAa,iBACpB,UAAU,aAAa,YACtB;;;;;;;;;;EAgBM,gBACP,cACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,UAE7B,SAAS,uBAAuB,cAAc,QAAQ,OAAO,aAC5D,QAAQ;;;;;EAKF,gBACP,cACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,UAE7B,SAAS,yBACP,uBAAuB,cAAc,QAAQ,OAAO,cAErD,QAAQ;EAqBF,eAAe,iBACtB,SAAS,aAAa,gBACrB,OAAO,UAAU;EAIX,aACP,wBACA,wBAAwB,WAAW,UACnC,uBAA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C7B,sBAEA,SAAS,aACP,0BACE,cACA,QACA,OACA,WACA,eAGH;EAsBM,kBAAkB,SAAS,aAAa;EAIxC,iBACP,wBACA,SAAS,cACT,QAAQ,cACR,aAAa,cAEb,UAAU,aAAa,WACvB,SAAS,aACP,KAAK,gBAAgB,cAAc,QAAQ,OAAO;EAM7C,iBACP,UAAU,aAAa,YACtB,UAAU;EAIJ,oBACP,iBACA,SAAS,cACT,mBACA,2BAEA,aAAa,aAAa,cAC1B,SAAS,aACP,wBAAwB,OAAO,QAAQ,YAAY;EAS9C,oBACP,aAAa,aAAa,eACzB"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as MaybeRef, l as NoUnknown, o as MaybeRefDeep, s as MaybeRefOrGetter, u as QueryClientConfig } from "./types-u_Tu5Ybs.js";
|
|
2
|
-
import { o as UseQueryOptions } from "./queryOptions-
|
|
2
|
+
import { o as UseQueryOptions } from "./queryOptions-D1-foH1W.js";
|
|
3
3
|
import { CancelOptions, DefaultError, DefaultOptions, EnsureQueryDataOptions, FetchInfiniteQueryOptions, FetchQueryOptions, InferDataFromTag, InferErrorFromTag, InfiniteData, InfiniteQueryExecuteOptions, InvalidateOptions, InvalidateQueryFilters, MutationFilters, MutationKey, MutationObserverOptions, OmitKeyof, QueryClient, QueryExecuteOptions, QueryFilters, QueryKey, QueryObserverOptions, QueryState, RefetchOptions, RefetchQueryFilters, ResetOptions, SetDataOptions, Updater } from "@tanstack/query-core";
|
|
4
4
|
import { Ref } from "vue-demi";
|
|
5
5
|
type VueQueryExecutionOptions<TOptions extends {
|
|
@@ -128,4 +128,4 @@ declare class QueryClient$1 extends QueryClient {
|
|
|
128
128
|
getMutationDefaults(mutationKey: MaybeRefDeep<MutationKey>): MutationObserverOptions<any, any, any, any>;
|
|
129
129
|
}
|
|
130
130
|
export { QueryClient$1 as t };
|
|
131
|
-
//# sourceMappingURL=queryClient-
|
|
131
|
+
//# sourceMappingURL=queryClient-Bgw9hMbf.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"queryClient-
|
|
1
|
+
{"version":3,"file":"queryClient-Bgw9hMbf.d.ts","names":["QueryClient","QC"],"sources":["../../src/queryClient.ts"],"mappings":";;;;KA2CK,yBAAyB;EAAmB;KAC/C,YACG,kBAAkB,WAAW,6BAC1B,aAAa,SAAS,sBACtB,8BACE,iBAAiB,aAAa,SAAS,cACvC,aAAa,SAAS;;;;;;;;;;;;;;;cAiBnBA,sBAAoBC;EACnB,YAAA,SAAQ;;;;;EAapB,cAAc;EAEL,WACP,UAAS,aAAa,KAAK;EAKpB,WACP,UAAS,aAAa,KAAK;EAKpB,aACP,iBACA,wBAAwB,WAAW,UAEnC,UAAU,kBACT,iBAAiB,OAAO;;EAElB,aAAa,iBACpB,UAAU,aAAa,YACtB;;;;;;;;;;EAgBM,gBACP,cACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,UAE7B,SAAS,uBAAuB,cAAc,QAAQ,OAAO,aAC5D,QAAQ;;;;;EAKF,gBACP,cACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,UAE7B,SAAS,yBACP,uBAAuB,cAAc,QAAQ,OAAO,cAErD,QAAQ;EAqBF,eAAe,iBACtB,SAAS,aAAa,gBACrB,OAAO,UAAU;EAIX,aACP,wBACA,wBAAwB,WAAW,UACnC,uBAAuB,iBAAiB,cAAc,kBAEtD,UAAU,iBACV,SAAS,QACP,iBAAiB,QAAQ,eAAe,8BACxC,QAAQ,oCAEV,UAAU,aAAa,kBACtB,QAAQ;;EAEF,aAAa,cAAc,QAAQ,UAAU,eACpD,UAAU,aAAa,WACvB,SAAS,QAAQ,QAAQ,oBAAoB,QAAQ,qBACrD,UAAU,aAAa,kBACtB,QAAQ;EAaF,eAAe,OACtB,SAAS,aAAa,eACtB,SAAS,QAAQ,mBAAmB,oBACpC,UAAS,aAAa,kBACrB,OAAO,UAAU;EAQX,cACP,wBACA,SAAS,cACT,wBAAwB,WAAW,UACnC,uBAAu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
|
|
1
|
-
import { t as QueryClient } from "./queryClient-
|
|
1
|
+
import { t as QueryClient } from "./queryClient-BSSPWSvX.cjs";
|
|
2
2
|
export { QueryClient };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as QueryClient } from "./queryClient-
|
|
1
|
+
import { t as QueryClient } from "./queryClient-Bgw9hMbf.js";
|
|
2
2
|
export { QueryClient };
|
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
import { a as MaybeRef, d as ShallowOption, o as MaybeRefDeep, s as MaybeRefOrGetter, t as DeepUnwrapRef } from "./types-u_Tu5Ybs.cjs";
|
|
2
2
|
import { DefaultError, InitialDataFunction, NonUndefinedGuard, QueryBooleanOption, QueryKey, QueryKeyWithDataTag, QueryObserverOptions } from "@tanstack/query-core";
|
|
3
|
+
/**
|
|
4
|
+
* `enabled` for Vue Query. A `ref`, `computed`, or plain boolean is reactive. A zero-argument getter
|
|
5
|
+
* (`() => ...`) is too: it is called while tracking dependencies. query-core's `(query) => boolean` is
|
|
6
|
+
* kept as that callback and is not tracked by Vue — a `ref` read inside it is current when core calls it,
|
|
7
|
+
* and a `ref` change does not by itself call it again.
|
|
8
|
+
*/
|
|
9
|
+
type VueQueryEnabledOption<TQueryFnData, TError, TQueryData, TQueryKey extends QueryKey> = MaybeRefOrGetter<boolean | undefined> | QueryBooleanOption<TQueryFnData, TError, TQueryData, TQueryKey>;
|
|
3
10
|
/**
|
|
4
11
|
* The plain, unwrapped options that `queryOptions` hands back, and what `useQuery`, `useQueries`, and the
|
|
5
12
|
* `queryClient` methods see once `ref`s have been resolved. To pass options in, use
|
|
@@ -11,11 +18,12 @@ import { DefaultError, InitialDataFunction, NonUndefinedGuard, QueryBooleanOptio
|
|
|
11
18
|
* `TQueryFnData` and can be configured independently of it.
|
|
12
19
|
* @template TQueryKey - The type of your `queryKey`.
|
|
13
20
|
*/
|
|
14
|
-
type QueryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryData = TQueryFnData, TQueryKey extends QueryKey = QueryKey> = { [Property in keyof QueryObserverOptions<TQueryFnData, TError, TData, TQueryData, TQueryKey>]: Property extends 'enabled' ?
|
|
21
|
+
type QueryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryData = TQueryFnData, TQueryKey extends QueryKey = QueryKey> = { [Property in keyof QueryObserverOptions<TQueryFnData, TError, TData, TQueryData, TQueryKey>]: Property extends 'enabled' ? VueQueryEnabledOption<TQueryFnData, TError, TQueryData, DeepUnwrapRef<TQueryKey>> : Property extends 'queryKey' ? MaybeRefOrGetter<TQueryKey> : QueryObserverOptions<TQueryFnData, TError, TData, TQueryData, DeepUnwrapRef<TQueryKey>>[Property]; } & ShallowOption;
|
|
15
22
|
type SkipTokenForUseQuery = symbol;
|
|
16
23
|
/**
|
|
17
24
|
* The options accepted by `queryOptions`, `useQuery`, and the other query hooks. `enabled` tracks reactive
|
|
18
|
-
* dependencies
|
|
25
|
+
* dependencies as a `ref`, a plain boolean, or a zero-argument getter (`() => ...`). query-core's
|
|
26
|
+
* `(query) => boolean` callback is accepted too and is passed through untracked. `queryKey` reacts
|
|
19
27
|
* through a `ref` or a reactive getter for the array itself, or `ref`s and reactive getters as individual
|
|
20
28
|
* entries. Other options are read once when passed as a plain value, and stay reactive when passed as a `ref`
|
|
21
29
|
* or a `computed`. Only `enabled` and `queryKey` read a function as a getter, so `queryFn` reacts through a
|
|
@@ -219,5 +227,5 @@ declare function queryOptions<TQueryFnData = unknown, TError = DefaultError, TDa
|
|
|
219
227
|
* ```
|
|
220
228
|
*/
|
|
221
229
|
declare function queryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryKey extends QueryKey = QueryKey>(options: () => UndefinedInitialQueryOptions<TQueryFnData, TError, TData, TQueryKey>): () => UndefinedInitialQueryOptionsWithDataTag<TQueryFnData, TError, TData, TQueryKey>;
|
|
222
|
-
export { UndefinedInitialQueryOptionsWithDataTag as a, UndefinedInitialQueryOptions as i, DefinedInitialQueryOptionsWithDataTag as n, UseQueryOptions as o, QueryOptions as r,
|
|
223
|
-
//# sourceMappingURL=queryOptions-
|
|
230
|
+
export { UndefinedInitialQueryOptionsWithDataTag as a, queryOptions as c, UndefinedInitialQueryOptions as i, DefinedInitialQueryOptionsWithDataTag as n, UseQueryOptions as o, QueryOptions as r, VueQueryEnabledOption as s, DefinedInitialQueryOptions as t };
|
|
231
|
+
//# sourceMappingURL=queryOptions-B-eHjgaY.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queryOptions-B-eHjgaY.d.cts","names":[],"sources":["../../src/queryOptions.ts"],"mappings":";;;;;;;;KAuBY,sBACV,cACA,QACA,YACA,kBAAkB,YAEhB,wCACA,mBAAmB,cAAc,QAAQ,YAAY;;;;;;;;;;;;KAa7C,aACV,wBACA,SAAS,cACT,QAAQ,cACR,aAAa,cACb,kBAAkB,WAAW,eAG3B,kBAAkB,qBAChB,cACA,QACA,OACA,YACA,aAED,6BACC,sBACE,cACA,QACA,YACA,cAAc,cAEhB,8BACE,iBAAiB,aACjB,qBACE,cACA,QACA,OACA,YACA,cAAc,YACd,eACN;KAGC;;;;;;;;;;;;;;;;;;;;;;;;;;KA2BO,gBACV,wBACA,SAAS,cACT,QAAQ,cACR,aAAa,cACb,kBAAkB,WAAW,YAC3B,YAGE,kBAAkB,qBAChB,cACA,QACA,OACA,YACA,aAED,0CACC,aACE,cACA,QACA,OACA,YACA,WACA,YACF,6BACE,aACI,aACE,cACA,QACA,OACA,YACA,WACA,YACF,wBAEJ,aACE,aACE,cACA,QACA,OACA,YACA,WACA,gBAER;KAGD,yBAAyB;;;;;;;;EAQ5B,0BAEI,oBAAoB,kBAAkB,iBACtC,kBAAkB;;KAGnB,uBAAuB;;;;;;;;EAQ1B,aACI,kBAAkB,uBACX,kBAAkB;;;;;;;;;;;KAYnB,6BACV,wBACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,YAC3B,gBAAgB,cAAc,QAAQ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{ DefaultError, InitialDataFunction, NonUndefinedGuard, QueryBooleanOption, QueryKey, QueryKeyWithDataTag, QueryObserverOptions } from "@tanstack/query-core";
|
|
3
|
+
/**
|
|
4
|
+
* `enabled` for Vue Query. A `ref`, `computed`, or plain boolean is reactive. A zero-argument getter
|
|
5
|
+
* (`() => ...`) is too: it is called while tracking dependencies. query-core's `(query) => boolean` is
|
|
6
|
+
* kept as that callback and is not tracked by Vue — a `ref` read inside it is current when core calls it,
|
|
7
|
+
* and a `ref` change does not by itself call it again.
|
|
8
|
+
*/
|
|
9
|
+
type VueQueryEnabledOption<TQueryFnData, TError, TQueryData, TQueryKey extends QueryKey> = MaybeRefOrGetter<boolean | undefined> | QueryBooleanOption<TQueryFnData, TError, TQueryData, TQueryKey>;
|
|
3
10
|
/**
|
|
4
11
|
* The plain, unwrapped options that `queryOptions` hands back, and what `useQuery`, `useQueries`, and the
|
|
5
12
|
* `queryClient` methods see once `ref`s have been resolved. To pass options in, use
|
|
@@ -11,11 +18,12 @@ import { DefaultError, InitialDataFunction, NonUndefinedGuard, QueryBooleanOptio
|
|
|
11
18
|
* `TQueryFnData` and can be configured independently of it.
|
|
12
19
|
* @template TQueryKey - The type of your `queryKey`.
|
|
13
20
|
*/
|
|
14
|
-
type QueryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryData = TQueryFnData, TQueryKey extends QueryKey = QueryKey> = { [Property in keyof QueryObserverOptions<TQueryFnData, TError, TData, TQueryData, TQueryKey>]: Property extends 'enabled' ?
|
|
21
|
+
type QueryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryData = TQueryFnData, TQueryKey extends QueryKey = QueryKey> = { [Property in keyof QueryObserverOptions<TQueryFnData, TError, TData, TQueryData, TQueryKey>]: Property extends 'enabled' ? VueQueryEnabledOption<TQueryFnData, TError, TQueryData, DeepUnwrapRef<TQueryKey>> : Property extends 'queryKey' ? MaybeRefOrGetter<TQueryKey> : QueryObserverOptions<TQueryFnData, TError, TData, TQueryData, DeepUnwrapRef<TQueryKey>>[Property]; } & ShallowOption;
|
|
15
22
|
type SkipTokenForUseQuery = symbol;
|
|
16
23
|
/**
|
|
17
24
|
* The options accepted by `queryOptions`, `useQuery`, and the other query hooks. `enabled` tracks reactive
|
|
18
|
-
* dependencies
|
|
25
|
+
* dependencies as a `ref`, a plain boolean, or a zero-argument getter (`() => ...`). query-core's
|
|
26
|
+
* `(query) => boolean` callback is accepted too and is passed through untracked. `queryKey` reacts
|
|
19
27
|
* through a `ref` or a reactive getter for the array itself, or `ref`s and reactive getters as individual
|
|
20
28
|
* entries. Other options are read once when passed as a plain value, and stay reactive when passed as a `ref`
|
|
21
29
|
* or a `computed`. Only `enabled` and `queryKey` read a function as a getter, so `queryFn` reacts through a
|
|
@@ -219,5 +227,5 @@ declare function queryOptions<TQueryFnData = unknown, TError = DefaultError, TDa
|
|
|
219
227
|
* ```
|
|
220
228
|
*/
|
|
221
229
|
declare function queryOptions<TQueryFnData = unknown, TError = DefaultError, TData = TQueryFnData, TQueryKey extends QueryKey = QueryKey>(options: () => UndefinedInitialQueryOptions<TQueryFnData, TError, TData, TQueryKey>): () => UndefinedInitialQueryOptionsWithDataTag<TQueryFnData, TError, TData, TQueryKey>;
|
|
222
|
-
export { UndefinedInitialQueryOptionsWithDataTag as a, UndefinedInitialQueryOptions as i, DefinedInitialQueryOptionsWithDataTag as n, UseQueryOptions as o, QueryOptions as r,
|
|
223
|
-
//# sourceMappingURL=queryOptions-
|
|
230
|
+
export { UndefinedInitialQueryOptionsWithDataTag as a, queryOptions as c, UndefinedInitialQueryOptions as i, DefinedInitialQueryOptionsWithDataTag as n, UseQueryOptions as o, QueryOptions as r, VueQueryEnabledOption as s, DefinedInitialQueryOptions as t };
|
|
231
|
+
//# sourceMappingURL=queryOptions-D1-foH1W.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queryOptions-D1-foH1W.d.ts","names":[],"sources":["../../src/queryOptions.ts"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aAC1D,uBAAuB,gBACvB,oBAAoB,WAAW,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA8B/B,aACd,wBACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,UAE7B,SAAS,2BAA2B,cAAc,QAAQ,OAAO,aAChE,sCAAsC,cAAc,QAAQ,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA4BtD,aACd,wBACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,UAE7B,eAAe,2BACb,cACA,QACA,OACA,mBAEK,sCACP,cACA,QACA,OACA;;;;;;;;;;;;;;;;;;;;;;;;;iBA2Bc,aACd,wBACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,UAE7B,SAAS,6BAA6B,cAAc,QAAQ,OAAO,aAClE,wCACD,cACA,QACA,OACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAoDc,aACd,wBACA,SAAS,cACT,QAAQ,cACR,kBAAkB,WAAW,UAE7B,eAAe,6BACb,cACA,QACA,OACA,mBAEK,wCACP,cACA,QACA,OACA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"queryOptions.cjs","names":[],"sources":["../../src/queryOptions.ts"],"sourcesContent":["import type {\n DeepUnwrapRef,\n MaybeRef,\n MaybeRefDeep,\n MaybeRefOrGetter,\n ShallowOption,\n} from './types'\nimport type {\n DefaultError,\n InitialDataFunction,\n NonUndefinedGuard,\n QueryBooleanOption,\n QueryKey,\n QueryKeyWithDataTag,\n QueryObserverOptions,\n} from '@tanstack/query-core'\n\n/**\n * The plain, unwrapped options that `queryOptions` hands back, and what `useQuery`, `useQueries`, and the\n * `queryClient` methods see once `ref`s have been resolved. To pass options in, use\n * {@link UseQueryOptions}, which accepts the same options as `ref`s and `computed`s too.\n * @template TQueryFnData - The type your `queryFn` resolves to.\n * @template TError - The type of errors your `queryFn` may throw.\n * @template TData - The type `data` ends up as after `select` runs.\n * @template TQueryData - The type of data stored in the cache, before `select` runs. Defaults to\n * `TQueryFnData` and can be configured independently of it.\n * @template TQueryKey - The type of your `queryKey`.\n */\nexport type QueryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = {\n [\n Property in keyof QueryObserverOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >\n ]: Property extends 'enabled'\n ?\n | MaybeRefOrGetter<boolean | undefined>\n | (() => QueryBooleanOption<\n TQueryFnData,\n TError,\n TQueryData,\n DeepUnwrapRef<TQueryKey>\n >)\n : Property extends 'queryKey'\n ? MaybeRefOrGetter<TQueryKey>\n : QueryObserverOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n DeepUnwrapRef<TQueryKey>\n >[Property]\n} & ShallowOption\n\n// Widen the type of the symbol to enable type inference even if skipToken is not immutable.\ntype SkipTokenForUseQuery = symbol\n\n/**\n * The options accepted by `queryOptions`, `useQuery`, and the other query hooks. `enabled` tracks reactive\n * dependencies automatically as a `ref`, a plain value, or a reactive getter (`() => ...`). `queryKey` reacts\n * through a `ref` or a reactive getter for the array itself, or `ref`s and reactive getters as individual\n * entries. Other options are read once when passed as a plain value, and stay reactive when passed as a `ref`\n * or a `computed`. Only `enabled` and `queryKey` read a function as a getter, so `queryFn` reacts through a\n * `computed`: a function there is the query function itself.\n *\n * If you instead pass a getter for the whole options object (`useQuery(() => ({ ... }))`), every option\n * inside it — including `staleTime`, `retry`, and `select` — is re-evaluated whenever the getter's own\n * reactive dependencies change, since the entire object is recomputed.\n *\n * `select` only re-runs when `data` changes, or when the `select` function's own reference changes. Since a\n * Vue `setup()` function runs only once per component instance, an inline `select` function passed directly\n * to `queryOptions`/`useQuery` already has a stable reference across reactive updates. An inline `select`\n * created inside a whole-options getter is recreated — and so can change reference — every time that getter\n * re-evaluates.\n * @template TQueryFnData - The type your `queryFn` resolves to.\n * @template TError - The type of errors your `queryFn` may throw.\n * @template TData - The type `data` ends up as after `select` runs.\n * @template TQueryData - The type of data stored in the cache, before `select` runs. Defaults to\n * `TQueryFnData` and can be configured independently of it.\n * @template TQueryKey - The type of your `queryKey`.\n */\nexport type UseQueryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = MaybeRef<\n {\n [\n Property in keyof QueryObserverOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >\n ]: Property extends 'enabled' | 'queryKey'\n ? QueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >[Property]\n : Property extends 'queryFn'\n ? MaybeRefDeep<\n | QueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >[Property]\n | SkipTokenForUseQuery\n >\n : MaybeRefDeep<\n QueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >[Property]\n >\n } & ShallowOption\n>\n\ntype WithUndefinedInitialData<TQueryFnData> = {\n /**\n * If set, this value will be used as the initial data for the query cache (as long as the query hasn't been\n * created or cached yet). If set to a function, the function will be called **once** during the shared/root\n * query initialization, and be expected to synchronously return the initial data. Initial data is\n * considered stale by default unless a `staleTime` has been set. `initialData` **is persisted** to the\n * cache. Unlike `queryKey`/`enabled`, this is not reactive — it isn't re-evaluated on `ref` changes.\n */\n initialData?:\n | undefined\n | InitialDataFunction<NonUndefinedGuard<TQueryFnData>>\n | NonUndefinedGuard<TQueryFnData>\n}\n\ntype WithDefinedInitialData<TQueryFnData> = {\n /**\n * If set, this value will be used as the initial data for the query cache (as long as the query hasn't been\n * created or cached yet). If set to a function, the function will be called **once** during the shared/root\n * query initialization, and be expected to synchronously return the initial data. Initial data is\n * considered stale by default unless a `staleTime` has been set. `initialData` **is persisted** to the\n * cache. Unlike `queryKey`/`enabled`, this is not reactive — it isn't re-evaluated on `ref` changes.\n */\n initialData:\n | NonUndefinedGuard<TQueryFnData>\n | (() => NonUndefinedGuard<TQueryFnData>)\n}\n\n/**\n * The options accepted by the `queryOptions` overload selected when `initialData` is omitted, may be\n * `undefined`, or is a function that may return `undefined` — `data` may be `undefined` while the query is\n * `pending`.\n * @template TQueryFnData - The type your `queryFn` resolves to.\n * @template TError - The type of errors your `queryFn` may throw.\n * @template TData - The type `data` ends up as after `select` runs.\n * @template TQueryKey - The type of your `queryKey`.\n */\nexport type UndefinedInitialQueryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = UseQueryOptions<TQueryFnData, TError, TData, TQueryFnData, TQueryKey> &\n WithUndefinedInitialData<TQueryFnData>\n\n/**\n * The options accepted by the `queryOptions` overload selected when `initialData` is known to be defined —\n * `data` is never `undefined` (unless a `select` changes `TData` to include `undefined`).\n * @template TQueryFnData - The type your `queryFn` resolves to.\n * @template TError - The type of errors your `queryFn` may throw.\n * @template TData - The type `data` ends up as after `select` runs.\n * @template TQueryKey - The type of your `queryKey`.\n */\nexport type DefinedInitialQueryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = UseQueryOptions<TQueryFnData, TError, TData, TQueryFnData, TQueryKey> &\n WithDefinedInitialData<TQueryFnData>\n\n/**\n * The options returned by the `queryOptions` overload selected when `initialData` is omitted, may be\n * `undefined`, or is a function that may return `undefined`, with the `queryKey` tagged with the query's data\n * and error types.\n */\nexport type UndefinedInitialQueryOptionsWithDataTag<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = QueryOptions<TQueryFnData, TError, TData, TQueryFnData, TQueryKey> &\n WithUndefinedInitialData<TQueryFnData> &\n QueryKeyWithDataTag<TQueryKey, TQueryFnData, TError>\n\n/**\n * The options returned by the `queryOptions` overload selected when `initialData` is known to be defined,\n * with the `queryKey` tagged with the query's data and error types.\n */\nexport type DefinedInitialQueryOptionsWithDataTag<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = QueryOptions<TQueryFnData, TError, TData, TQueryFnData, TQueryKey> &\n WithDefinedInitialData<TQueryFnData> &\n QueryKeyWithDataTag<TQueryKey, TQueryFnData, TError>\n\n/**\n * You can generally pass everything to `queryOptions` that you can also pass to `useQuery`. These options can\n * be shared across hooks and imperative APIs such as `queryClient.query`. `options.queryKey` is required and\n * is the query key to generate options for.\n *\n * This overload is selected when `initialData` is known to be defined, so the resulting `data` is never\n * `undefined` (unless a `select` changes `TData` to include `undefined`).\n * @param options - The {@link DefinedInitialQueryOptions} to use — everything you can pass to `useQuery`,\n * with `initialData` known to be defined.\n * @returns The same options object, typed so that `queryKey` carries the inferred data type.\n * @see {@link useQuery} to run a query with these options.\n * @example\n * ```vue\n * <script setup lang=\"ts\">\n * import { queryOptions, useQuery } from '@tanstack/vue-query'\n *\n * const postsOptions = queryOptions({\n * queryKey: ['posts'],\n * queryFn: fetchPosts,\n * initialData: [],\n * })\n *\n * // `data` is `Post[]`, never `undefined`, thanks to `initialData` — even if a refetch fails,\n * // so the list stays visible alongside the error.\n * const { data, isError, error } = useQuery(postsOptions)\n * </script>\n * ```\n */\nexport function queryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n options: DefinedInitialQueryOptions<TQueryFnData, TError, TData, TQueryKey>,\n): DefinedInitialQueryOptionsWithDataTag<TQueryFnData, TError, TData, TQueryKey>\n\n/**\n * Same as the plain-object overload, but for options that close over reactive state (`ref`s read inside the\n * function body). Wrap them in a getter so `queryClient` methods like `invalidateQueries`/`fetchQuery` always\n * read the current values instead of the ones captured when the options were created.\n * @param options - A function returning the {@link DefinedInitialQueryOptions} to use, re-evaluated on demand.\n * @returns A function that returns the same options object, typed so that `queryKey` carries the inferred data\n * type.\n * @see {@link useQuery} to run a query with these options.\n * @example\n * ```vue\n * <script setup lang=\"ts\">\n * import { ref } from 'vue'\n * import { queryOptions, useQuery } from '@tanstack/vue-query'\n *\n * const postId = ref(1)\n * const postOptions = queryOptions(() => ({\n * queryKey: ['post', postId.value],\n * queryFn: () => fetchPost(postId.value),\n * initialData: { id: postId.value, title: '' },\n * }))\n *\n * // Pass the getter itself, not `postOptions()`, so the query keeps reacting to `postId` changes.\n * const { data } = useQuery(postOptions)\n * </script>\n * ```\n */\nexport function queryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n options: () => DefinedInitialQueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n >,\n): () => DefinedInitialQueryOptionsWithDataTag<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n>\n\n/**\n * You can generally pass everything to `queryOptions` that you can also pass to `useQuery`. These options can\n * be shared across hooks and imperative APIs such as `queryClient.query`. `options.queryKey` is required and\n * is the query key to generate options for.\n * @param options - The {@link UndefinedInitialQueryOptions} to use — everything you can pass to `useQuery`.\n * @returns The same options object, typed so that `queryKey` carries the inferred data type.\n * @see {@link useQuery} to run a query with these options.\n * @example\n * A parameterized factory, so the same options object can be reused per `id`:\n * ```vue\n * <script setup lang=\"ts\">\n * import { queryOptions, useQuery } from '@tanstack/vue-query'\n *\n * function postOptions(id: string) {\n * return queryOptions({\n * queryKey: ['post', id],\n * queryFn: () => fetchPost(id),\n * })\n * }\n *\n * const { data, isPending, isError, error } = useQuery(postOptions('1'))\n * </script>\n * ```\n */\nexport function queryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n options: UndefinedInitialQueryOptions<TQueryFnData, TError, TData, TQueryKey>,\n): UndefinedInitialQueryOptionsWithDataTag<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n>\n\n/**\n * Same as the plain-object overload, but for options that close over reactive state (`ref`s read inside the\n * function body). Wrap them in a getter so the `queryKey` — and anything else derived from a `ref` — reacts\n * to changes, and so `queryClient` methods like `invalidateQueries`/`fetchQuery` always read the current\n * values instead of the ones captured when the options were created.\n * @param options - A function returning the {@link UndefinedInitialQueryOptions} to use, re-evaluated on\n * demand.\n * @returns A function that returns the same options object, typed so that `queryKey` carries the inferred\n * data type.\n * @see {@link useQuery} to run a query with these options.\n * @example\n * ```vue\n * <script setup lang=\"ts\">\n * import { ref } from 'vue'\n * import { queryOptions, useQuery, useQueryClient } from '@tanstack/vue-query'\n *\n * const postId = ref(1)\n * const postOptions = queryOptions(() => ({\n * queryKey: ['post', postId.value],\n * queryFn: () => fetchPost(postId.value),\n * }))\n *\n * // Pass the getter itself, not `postOptions()`, so the query keeps reacting to `postId` changes.\n * const { data } = useQuery(postOptions)\n * const queryClient = useQueryClient()\n * // Here, call `postOptions()` so `invalidateQueries` reads the current `queryKey` right away.\n * queryClient.invalidateQueries(postOptions())\n * </script>\n * ```\n * @example\n * A parameterized factory that disables the query, type safe, until `postId` is set. The whole-options getter\n * re-evaluates `queryFn` on every change to `postId`. `queryFn` can also be a `computed`, but never a bare\n * getter, since a function there is the query function itself:\n * ```vue\n * <script setup lang=\"ts\">\n * import { queryOptions, skipToken, useQuery } from '@tanstack/vue-query'\n *\n * function postOptions(postId: number | undefined) {\n * return queryOptions(() => ({\n * queryKey: ['post', postId],\n * queryFn: postId != null ? () => fetchPost(postId) : skipToken,\n * }))\n * }\n *\n * const props = defineProps<{ postId: number | undefined }>()\n * const { data, isLoading, isError, error } = useQuery(postOptions(props.postId))\n * </script>\n * ```\n */\nexport function queryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n options: () => UndefinedInitialQueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n >,\n): () => UndefinedInitialQueryOptionsWithDataTag<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n>\n\nexport function queryOptions(options: unknown) {\n return options\n}\n"],"mappings":";;AA4ZA,SAAgB,aAAa,SAAkB;CAC7C,OAAO;AACT"}
|
|
1
|
+
{"version":3,"file":"queryOptions.cjs","names":[],"sources":["../../src/queryOptions.ts"],"sourcesContent":["import type {\n DeepUnwrapRef,\n MaybeRef,\n MaybeRefDeep,\n MaybeRefOrGetter,\n ShallowOption,\n} from './types'\nimport type {\n DefaultError,\n InitialDataFunction,\n NonUndefinedGuard,\n QueryBooleanOption,\n QueryKey,\n QueryKeyWithDataTag,\n QueryObserverOptions,\n} from '@tanstack/query-core'\n\n/**\n * `enabled` for Vue Query. A `ref`, `computed`, or plain boolean is reactive. A zero-argument getter\n * (`() => ...`) is too: it is called while tracking dependencies. query-core's `(query) => boolean` is\n * kept as that callback and is not tracked by Vue — a `ref` read inside it is current when core calls it,\n * and a `ref` change does not by itself call it again.\n */\nexport type VueQueryEnabledOption<\n TQueryFnData,\n TError,\n TQueryData,\n TQueryKey extends QueryKey,\n> =\n | MaybeRefOrGetter<boolean | undefined>\n | QueryBooleanOption<TQueryFnData, TError, TQueryData, TQueryKey>\n\n/**\n * The plain, unwrapped options that `queryOptions` hands back, and what `useQuery`, `useQueries`, and the\n * `queryClient` methods see once `ref`s have been resolved. To pass options in, use\n * {@link UseQueryOptions}, which accepts the same options as `ref`s and `computed`s too.\n * @template TQueryFnData - The type your `queryFn` resolves to.\n * @template TError - The type of errors your `queryFn` may throw.\n * @template TData - The type `data` ends up as after `select` runs.\n * @template TQueryData - The type of data stored in the cache, before `select` runs. Defaults to\n * `TQueryFnData` and can be configured independently of it.\n * @template TQueryKey - The type of your `queryKey`.\n */\nexport type QueryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = {\n [\n Property in keyof QueryObserverOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >\n ]: Property extends 'enabled'\n ? VueQueryEnabledOption<\n TQueryFnData,\n TError,\n TQueryData,\n DeepUnwrapRef<TQueryKey>\n >\n : Property extends 'queryKey'\n ? MaybeRefOrGetter<TQueryKey>\n : QueryObserverOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n DeepUnwrapRef<TQueryKey>\n >[Property]\n} & ShallowOption\n\n// Widen the type of the symbol to enable type inference even if skipToken is not immutable.\ntype SkipTokenForUseQuery = symbol\n\n/**\n * The options accepted by `queryOptions`, `useQuery`, and the other query hooks. `enabled` tracks reactive\n * dependencies as a `ref`, a plain boolean, or a zero-argument getter (`() => ...`). query-core's\n * `(query) => boolean` callback is accepted too and is passed through untracked. `queryKey` reacts\n * through a `ref` or a reactive getter for the array itself, or `ref`s and reactive getters as individual\n * entries. Other options are read once when passed as a plain value, and stay reactive when passed as a `ref`\n * or a `computed`. Only `enabled` and `queryKey` read a function as a getter, so `queryFn` reacts through a\n * `computed`: a function there is the query function itself.\n *\n * If you instead pass a getter for the whole options object (`useQuery(() => ({ ... }))`), every option\n * inside it — including `staleTime`, `retry`, and `select` — is re-evaluated whenever the getter's own\n * reactive dependencies change, since the entire object is recomputed.\n *\n * `select` only re-runs when `data` changes, or when the `select` function's own reference changes. Since a\n * Vue `setup()` function runs only once per component instance, an inline `select` function passed directly\n * to `queryOptions`/`useQuery` already has a stable reference across reactive updates. An inline `select`\n * created inside a whole-options getter is recreated — and so can change reference — every time that getter\n * re-evaluates.\n * @template TQueryFnData - The type your `queryFn` resolves to.\n * @template TError - The type of errors your `queryFn` may throw.\n * @template TData - The type `data` ends up as after `select` runs.\n * @template TQueryData - The type of data stored in the cache, before `select` runs. Defaults to\n * `TQueryFnData` and can be configured independently of it.\n * @template TQueryKey - The type of your `queryKey`.\n */\nexport type UseQueryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = MaybeRef<\n {\n [\n Property in keyof QueryObserverOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >\n ]: Property extends 'enabled' | 'queryKey'\n ? QueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >[Property]\n : Property extends 'queryFn'\n ? MaybeRefDeep<\n | QueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >[Property]\n | SkipTokenForUseQuery\n >\n : MaybeRefDeep<\n QueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryData,\n TQueryKey\n >[Property]\n >\n } & ShallowOption\n>\n\ntype WithUndefinedInitialData<TQueryFnData> = {\n /**\n * If set, this value will be used as the initial data for the query cache (as long as the query hasn't been\n * created or cached yet). If set to a function, the function will be called **once** during the shared/root\n * query initialization, and be expected to synchronously return the initial data. Initial data is\n * considered stale by default unless a `staleTime` has been set. `initialData` **is persisted** to the\n * cache. Unlike `queryKey`/`enabled`, this is not reactive — it isn't re-evaluated on `ref` changes.\n */\n initialData?:\n | undefined\n | InitialDataFunction<NonUndefinedGuard<TQueryFnData>>\n | NonUndefinedGuard<TQueryFnData>\n}\n\ntype WithDefinedInitialData<TQueryFnData> = {\n /**\n * If set, this value will be used as the initial data for the query cache (as long as the query hasn't been\n * created or cached yet). If set to a function, the function will be called **once** during the shared/root\n * query initialization, and be expected to synchronously return the initial data. Initial data is\n * considered stale by default unless a `staleTime` has been set. `initialData` **is persisted** to the\n * cache. Unlike `queryKey`/`enabled`, this is not reactive — it isn't re-evaluated on `ref` changes.\n */\n initialData:\n | NonUndefinedGuard<TQueryFnData>\n | (() => NonUndefinedGuard<TQueryFnData>)\n}\n\n/**\n * The options accepted by the `queryOptions` overload selected when `initialData` is omitted, may be\n * `undefined`, or is a function that may return `undefined` — `data` may be `undefined` while the query is\n * `pending`.\n * @template TQueryFnData - The type your `queryFn` resolves to.\n * @template TError - The type of errors your `queryFn` may throw.\n * @template TData - The type `data` ends up as after `select` runs.\n * @template TQueryKey - The type of your `queryKey`.\n */\nexport type UndefinedInitialQueryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = UseQueryOptions<TQueryFnData, TError, TData, TQueryFnData, TQueryKey> &\n WithUndefinedInitialData<TQueryFnData>\n\n/**\n * The options accepted by the `queryOptions` overload selected when `initialData` is known to be defined —\n * `data` is never `undefined` (unless a `select` changes `TData` to include `undefined`).\n * @template TQueryFnData - The type your `queryFn` resolves to.\n * @template TError - The type of errors your `queryFn` may throw.\n * @template TData - The type `data` ends up as after `select` runs.\n * @template TQueryKey - The type of your `queryKey`.\n */\nexport type DefinedInitialQueryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = UseQueryOptions<TQueryFnData, TError, TData, TQueryFnData, TQueryKey> &\n WithDefinedInitialData<TQueryFnData>\n\n/**\n * The options returned by the `queryOptions` overload selected when `initialData` is omitted, may be\n * `undefined`, or is a function that may return `undefined`, with the `queryKey` tagged with the query's data\n * and error types.\n */\nexport type UndefinedInitialQueryOptionsWithDataTag<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = QueryOptions<TQueryFnData, TError, TData, TQueryFnData, TQueryKey> &\n WithUndefinedInitialData<TQueryFnData> &\n QueryKeyWithDataTag<TQueryKey, TQueryFnData, TError>\n\n/**\n * The options returned by the `queryOptions` overload selected when `initialData` is known to be defined,\n * with the `queryKey` tagged with the query's data and error types.\n */\nexport type DefinedInitialQueryOptionsWithDataTag<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n> = QueryOptions<TQueryFnData, TError, TData, TQueryFnData, TQueryKey> &\n WithDefinedInitialData<TQueryFnData> &\n QueryKeyWithDataTag<TQueryKey, TQueryFnData, TError>\n\n/**\n * You can generally pass everything to `queryOptions` that you can also pass to `useQuery`. These options can\n * be shared across hooks and imperative APIs such as `queryClient.query`. `options.queryKey` is required and\n * is the query key to generate options for.\n *\n * This overload is selected when `initialData` is known to be defined, so the resulting `data` is never\n * `undefined` (unless a `select` changes `TData` to include `undefined`).\n * @param options - The {@link DefinedInitialQueryOptions} to use — everything you can pass to `useQuery`,\n * with `initialData` known to be defined.\n * @returns The same options object, typed so that `queryKey` carries the inferred data type.\n * @see {@link useQuery} to run a query with these options.\n * @example\n * ```vue\n * <script setup lang=\"ts\">\n * import { queryOptions, useQuery } from '@tanstack/vue-query'\n *\n * const postsOptions = queryOptions({\n * queryKey: ['posts'],\n * queryFn: fetchPosts,\n * initialData: [],\n * })\n *\n * // `data` is `Post[]`, never `undefined`, thanks to `initialData` — even if a refetch fails,\n * // so the list stays visible alongside the error.\n * const { data, isError, error } = useQuery(postsOptions)\n * </script>\n * ```\n */\nexport function queryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n options: DefinedInitialQueryOptions<TQueryFnData, TError, TData, TQueryKey>,\n): DefinedInitialQueryOptionsWithDataTag<TQueryFnData, TError, TData, TQueryKey>\n\n/**\n * Same as the plain-object overload, but for options that close over reactive state (`ref`s read inside the\n * function body). Wrap them in a getter so `queryClient` methods like `invalidateQueries`/`fetchQuery` always\n * read the current values instead of the ones captured when the options were created.\n * @param options - A function returning the {@link DefinedInitialQueryOptions} to use, re-evaluated on demand.\n * @returns A function that returns the same options object, typed so that `queryKey` carries the inferred data\n * type.\n * @see {@link useQuery} to run a query with these options.\n * @example\n * ```vue\n * <script setup lang=\"ts\">\n * import { ref } from 'vue'\n * import { queryOptions, useQuery } from '@tanstack/vue-query'\n *\n * const postId = ref(1)\n * const postOptions = queryOptions(() => ({\n * queryKey: ['post', postId.value],\n * queryFn: () => fetchPost(postId.value),\n * initialData: { id: postId.value, title: '' },\n * }))\n *\n * // Pass the getter itself, not `postOptions()`, so the query keeps reacting to `postId` changes.\n * const { data } = useQuery(postOptions)\n * </script>\n * ```\n */\nexport function queryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n options: () => DefinedInitialQueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n >,\n): () => DefinedInitialQueryOptionsWithDataTag<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n>\n\n/**\n * You can generally pass everything to `queryOptions` that you can also pass to `useQuery`. These options can\n * be shared across hooks and imperative APIs such as `queryClient.query`. `options.queryKey` is required and\n * is the query key to generate options for.\n * @param options - The {@link UndefinedInitialQueryOptions} to use — everything you can pass to `useQuery`.\n * @returns The same options object, typed so that `queryKey` carries the inferred data type.\n * @see {@link useQuery} to run a query with these options.\n * @example\n * A parameterized factory, so the same options object can be reused per `id`:\n * ```vue\n * <script setup lang=\"ts\">\n * import { queryOptions, useQuery } from '@tanstack/vue-query'\n *\n * function postOptions(id: string) {\n * return queryOptions({\n * queryKey: ['post', id],\n * queryFn: () => fetchPost(id),\n * })\n * }\n *\n * const { data, isPending, isError, error } = useQuery(postOptions('1'))\n * </script>\n * ```\n */\nexport function queryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n options: UndefinedInitialQueryOptions<TQueryFnData, TError, TData, TQueryKey>,\n): UndefinedInitialQueryOptionsWithDataTag<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n>\n\n/**\n * Same as the plain-object overload, but for options that close over reactive state (`ref`s read inside the\n * function body). Wrap them in a getter so the `queryKey` — and anything else derived from a `ref` — reacts\n * to changes, and so `queryClient` methods like `invalidateQueries`/`fetchQuery` always read the current\n * values instead of the ones captured when the options were created.\n * @param options - A function returning the {@link UndefinedInitialQueryOptions} to use, re-evaluated on\n * demand.\n * @returns A function that returns the same options object, typed so that `queryKey` carries the inferred\n * data type.\n * @see {@link useQuery} to run a query with these options.\n * @example\n * ```vue\n * <script setup lang=\"ts\">\n * import { ref } from 'vue'\n * import { queryOptions, useQuery, useQueryClient } from '@tanstack/vue-query'\n *\n * const postId = ref(1)\n * const postOptions = queryOptions(() => ({\n * queryKey: ['post', postId.value],\n * queryFn: () => fetchPost(postId.value),\n * }))\n *\n * // Pass the getter itself, not `postOptions()`, so the query keeps reacting to `postId` changes.\n * const { data } = useQuery(postOptions)\n * const queryClient = useQueryClient()\n * // Here, call `postOptions()` so `invalidateQueries` reads the current `queryKey` right away.\n * queryClient.invalidateQueries(postOptions())\n * </script>\n * ```\n * @example\n * A parameterized factory that disables the query, type safe, until `postId` is set. The whole-options getter\n * re-evaluates `queryFn` on every change to `postId`. `queryFn` can also be a `computed`, but never a bare\n * getter, since a function there is the query function itself:\n * ```vue\n * <script setup lang=\"ts\">\n * import { queryOptions, skipToken, useQuery } from '@tanstack/vue-query'\n *\n * function postOptions(postId: number | undefined) {\n * return queryOptions(() => ({\n * queryKey: ['post', postId],\n * queryFn: postId != null ? () => fetchPost(postId) : skipToken,\n * }))\n * }\n *\n * const props = defineProps<{ postId: number | undefined }>()\n * const { data, isLoading, isError, error } = useQuery(postOptions(props.postId))\n * </script>\n * ```\n */\nexport function queryOptions<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n options: () => UndefinedInitialQueryOptions<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n >,\n): () => UndefinedInitialQueryOptionsWithDataTag<\n TQueryFnData,\n TError,\n TData,\n TQueryKey\n>\n\nexport function queryOptions(options: unknown) {\n return options\n}\n"],"mappings":";;AA0aA,SAAgB,aAAa,SAAkB;CAC7C,OAAO;AACT"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as UndefinedInitialQueryOptionsWithDataTag, i as UndefinedInitialQueryOptions, n as DefinedInitialQueryOptionsWithDataTag, o as UseQueryOptions, r as QueryOptions, s as
|
|
2
|
-
export { DefinedInitialQueryOptions, DefinedInitialQueryOptionsWithDataTag, QueryOptions, UndefinedInitialQueryOptions, UndefinedInitialQueryOptionsWithDataTag, UseQueryOptions, queryOptions };
|
|
1
|
+
import { a as UndefinedInitialQueryOptionsWithDataTag, c as queryOptions, i as UndefinedInitialQueryOptions, n as DefinedInitialQueryOptionsWithDataTag, o as UseQueryOptions, r as QueryOptions, s as VueQueryEnabledOption, t as DefinedInitialQueryOptions } from "./queryOptions-B-eHjgaY.cjs";
|
|
2
|
+
export { DefinedInitialQueryOptions, DefinedInitialQueryOptionsWithDataTag, QueryOptions, UndefinedInitialQueryOptions, UndefinedInitialQueryOptionsWithDataTag, UseQueryOptions, VueQueryEnabledOption, queryOptions };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as UndefinedInitialQueryOptionsWithDataTag, i as UndefinedInitialQueryOptions, n as DefinedInitialQueryOptionsWithDataTag, o as UseQueryOptions, r as QueryOptions, s as
|
|
2
|
-
export { DefinedInitialQueryOptions, DefinedInitialQueryOptionsWithDataTag, QueryOptions, UndefinedInitialQueryOptions, UndefinedInitialQueryOptionsWithDataTag, UseQueryOptions, queryOptions };
|
|
1
|
+
import { a as UndefinedInitialQueryOptionsWithDataTag, c as queryOptions, i as UndefinedInitialQueryOptions, n as DefinedInitialQueryOptionsWithDataTag, o as UseQueryOptions, r as QueryOptions, s as VueQueryEnabledOption, t as DefinedInitialQueryOptions } from "./queryOptions-D1-foH1W.js";
|
|
2
|
+
export { DefinedInitialQueryOptions, DefinedInitialQueryOptionsWithDataTag, QueryOptions, UndefinedInitialQueryOptions, UndefinedInitialQueryOptionsWithDataTag, UseQueryOptions, VueQueryEnabledOption, queryOptions };
|