From 0b2c9d7fe11e2ae75c36212714d8013f6f4148a7 Mon Sep 17 00:00:00 2001 From: Lachlan Collins <1667261+lachlancollins@users.noreply.github.com> Date: Sat, 27 Jul 2024 12:58:31 +1000 Subject: [PATCH] docs(typedoc): use sub-folders for reference docs --- docs/config.json | 12 +- .../infinitequeryoptions.md} | 24 +++- .../injectinfinitequery.md} | 42 ++++++- .../injectisfetching.md} | 2 +- .../injectismutating.md} | 2 +- .../injectmutation.md} | 4 +- .../injectmutationstate.md} | 4 +- .../injectqueries.md} | 2 +- .../injectquery.md} | 54 ++++++++- .../injectqueryclient.md} | 6 +- .../provideangularquery.md} | 2 +- .../providequeryclient.md} | 4 +- .../queryoptions.md} | 24 +++- docs/framework/angular/reference/index.md | 70 ++++++------ .../basemutationnarrowing.md} | 16 +-- .../basequerynarrowing.md} | 12 +- .../createbasequeryoptions.md} | 0 .../createinfinitequeryoptions.md} | 0 .../createmutationoptions.md} | 0 .../createqueryoptions.md} | 2 +- .../injectmutationstateoptions.md} | 2 +- .../createbasemutationresult.md} | 2 +- .../createbasequeryresult.md} | 2 +- .../createinfinitequeryresult.md} | 2 +- .../createmutateasyncfunction.md} | 2 +- .../createmutatefunction.md} | 2 +- .../createmutationresult.md} | 4 +- .../createqueryresult.md} | 2 +- .../definedcreateinfinitequeryresult.md} | 2 +- .../definedcreatequeryresult.md} | 2 +- .../definedinitialdatainfiniteoptions.md} | 2 +- .../definedinitialdataoptions.md} | 2 +- .../nonundefinedguard.md} | 2 +- .../queriesoptions.md} | 2 +- .../queriesresults.md} | 2 +- .../undefinedinitialdatainfiniteoptions.md} | 2 +- .../undefinedinitialdataoptions.md} | 2 +- .../svelte/reference/QueriesOptions.md | 24 ---- .../svelte/reference/QueriesResults.md | 24 ---- .../hydrationboundary.md} | 2 +- .../svelte/reference/createQueries.md | 37 ------ .../framework/svelte/reference/createQuery.md | 72 ------------ .../createinfinitequery.md} | 6 +- .../createmutation.md} | 6 +- .../reference/functions/createqueries.md | 37 ++++++ .../svelte/reference/functions/createquery.md | 105 ++++++++++++++++++ .../getisrestoringcontext.md} | 2 +- .../getqueryclientcontext.md} | 2 +- .../infinitequeryoptions.md} | 6 +- .../queryoptions.md} | 16 +-- .../setisrestoringcontext.md} | 2 +- .../setqueryclientcontext.md} | 2 +- .../usehydrate.md} | 2 +- .../useisfetching.md} | 2 +- .../useismutating.md} | 2 +- .../useisrestoring.md} | 2 +- .../usemutationstate.md} | 4 +- .../usequeryclient.md} | 2 +- docs/framework/svelte/reference/index.md | 74 ++++++------ .../createbasemutationresult.md} | 2 +- .../createbasequeryoptions.md} | 2 +- .../createbasequeryresult.md} | 2 +- .../createinfinitequeryoptions.md} | 2 +- .../createinfinitequeryresult.md} | 2 +- .../createmutateasyncfunction.md} | 2 +- .../createmutatefunction.md} | 2 +- .../createmutationoptions.md} | 2 +- .../createmutationresult.md} | 2 +- .../createqueryoptions.md} | 2 +- .../createqueryresult.md} | 2 +- .../definedcreatebasequeryresult.md} | 2 +- .../definedcreatequeryresult.md} | 2 +- .../definedinitialdataoptions.md} | 2 +- .../mutationstateoptions.md} | 2 +- .../reference/type-aliases/queriesoptions.md | 24 ++++ .../reference/type-aliases/queriesresults.md | 24 ++++ .../storeorval.md} | 2 +- .../undefinedinitialdataoptions.md} | 2 +- package.json | 2 +- pnpm-lock.yaml | 12 +- 80 files changed, 491 insertions(+), 354 deletions(-) rename docs/framework/angular/reference/{infiniteQueryOptions.md => functions/infinitequeryoptions.md} (66%) rename docs/framework/angular/reference/{injectInfiniteQuery.md => functions/injectinfinitequery.md} (78%) rename docs/framework/angular/reference/{injectIsFetching.md => functions/injectisfetching.md} (91%) rename docs/framework/angular/reference/{injectIsMutating.md => functions/injectismutating.md} (90%) rename docs/framework/angular/reference/{injectMutation.md => functions/injectmutation.md} (75%) rename docs/framework/angular/reference/{injectMutationState.md => functions/injectmutationstate.md} (81%) rename docs/framework/angular/reference/{injectQueries.md => functions/injectqueries.md} (94%) rename docs/framework/angular/reference/{injectQuery.md => functions/injectquery.md} (82%) rename docs/framework/angular/reference/{injectQueryClient.md => functions/injectqueryclient.md} (88%) rename docs/framework/angular/reference/{provideAngularQuery.md => functions/provideangularquery.md} (89%) rename docs/framework/angular/reference/{provideQueryClient.md => functions/providequeryclient.md} (84%) rename docs/framework/angular/reference/{queryOptions.md => functions/queryoptions.md} (69%) rename docs/framework/angular/reference/{BaseMutationNarrowing.md => interfaces/basemutationnarrowing.md} (57%) rename docs/framework/angular/reference/{BaseQueryNarrowing.md => interfaces/basequerynarrowing.md} (58%) rename docs/framework/angular/reference/{CreateBaseQueryOptions.md => interfaces/createbasequeryoptions.md} (100%) rename docs/framework/angular/reference/{CreateInfiniteQueryOptions.md => interfaces/createinfinitequeryoptions.md} (100%) rename docs/framework/angular/reference/{CreateMutationOptions.md => interfaces/createmutationoptions.md} (100%) rename docs/framework/angular/reference/{CreateQueryOptions.md => interfaces/createqueryoptions.md} (86%) rename docs/framework/angular/reference/{InjectMutationStateOptions.md => interfaces/injectmutationstateoptions.md} (83%) rename docs/framework/angular/reference/{CreateBaseMutationResult.md => type-aliases/createbasemutationresult.md} (82%) rename docs/framework/angular/reference/{CreateBaseQueryResult.md => type-aliases/createbasequeryresult.md} (78%) rename docs/framework/angular/reference/{CreateInfiniteQueryResult.md => type-aliases/createinfinitequeryresult.md} (73%) rename docs/framework/angular/reference/{CreateMutateAsyncFunction.md => type-aliases/createmutateasyncfunction.md} (78%) rename docs/framework/angular/reference/{CreateMutateFunction.md => type-aliases/createmutatefunction.md} (80%) rename docs/framework/angular/reference/{CreateMutationResult.md => type-aliases/createmutationresult.md} (77%) rename docs/framework/angular/reference/{CreateQueryResult.md => type-aliases/createqueryresult.md} (70%) rename docs/framework/angular/reference/{DefinedCreateInfiniteQueryResult.md => type-aliases/definedcreateinfinitequeryresult.md} (80%) rename docs/framework/angular/reference/{DefinedCreateQueryResult.md => type-aliases/definedcreatequeryresult.md} (78%) rename docs/framework/angular/reference/{DefinedInitialDataInfiniteOptions.md => type-aliases/definedinitialdatainfiniteoptions.md} (93%) rename docs/framework/angular/reference/{DefinedInitialDataOptions.md => type-aliases/definedinitialdataoptions.md} (83%) rename docs/framework/angular/reference/{NonUndefinedGuard.md => type-aliases/nonundefinedguard.md} (64%) rename docs/framework/angular/reference/{QueriesOptions.md => type-aliases/queriesoptions.md} (88%) rename docs/framework/angular/reference/{QueriesResults.md => type-aliases/queriesresults.md} (87%) rename docs/framework/angular/reference/{UndefinedInitialDataInfiniteOptions.md => type-aliases/undefinedinitialdatainfiniteoptions.md} (92%) rename docs/framework/angular/reference/{UndefinedInitialDataOptions.md => type-aliases/undefinedinitialdataoptions.md} (82%) delete mode 100644 docs/framework/svelte/reference/QueriesOptions.md delete mode 100644 docs/framework/svelte/reference/QueriesResults.md rename docs/framework/svelte/reference/{HydrationBoundary.md => classes/hydrationboundary.md} (98%) delete mode 100644 docs/framework/svelte/reference/createQueries.md delete mode 100644 docs/framework/svelte/reference/createQuery.md rename docs/framework/svelte/reference/{createInfiniteQuery.md => functions/createinfinitequery.md} (58%) rename docs/framework/svelte/reference/{createMutation.md => functions/createmutation.md} (61%) create mode 100644 docs/framework/svelte/reference/functions/createqueries.md create mode 100644 docs/framework/svelte/reference/functions/createquery.md rename docs/framework/svelte/reference/{getIsRestoringContext.md => functions/getisrestoringcontext.md} (85%) rename docs/framework/svelte/reference/{getQueryClientContext.md => functions/getqueryclientcontext.md} (84%) rename docs/framework/svelte/reference/{infiniteQueryOptions.md => functions/infinitequeryoptions.md} (58%) rename docs/framework/svelte/reference/{queryOptions.md => functions/queryoptions.md} (61%) rename docs/framework/svelte/reference/{setIsRestoringContext.md => functions/setisrestoringcontext.md} (86%) rename docs/framework/svelte/reference/{setQueryClientContext.md => functions/setqueryclientcontext.md} (85%) rename docs/framework/svelte/reference/{useHydrate.md => functions/usehydrate.md} (85%) rename docs/framework/svelte/reference/{useIsFetching.md => functions/useisfetching.md} (86%) rename docs/framework/svelte/reference/{useIsMutating.md => functions/useismutating.md} (86%) rename docs/framework/svelte/reference/{useIsRestoring.md => functions/useisrestoring.md} (82%) rename docs/framework/svelte/reference/{useMutationState.md => functions/usemutationstate.md} (66%) rename docs/framework/svelte/reference/{useQueryClient.md => functions/usequeryclient.md} (84%) rename docs/framework/svelte/reference/{CreateBaseMutationResult.md => type-aliases/createbasemutationresult.md} (91%) rename docs/framework/svelte/reference/{CreateBaseQueryOptions.md => type-aliases/createbasequeryoptions.md} (91%) rename docs/framework/svelte/reference/{CreateBaseQueryResult.md => type-aliases/createbasequeryresult.md} (87%) rename docs/framework/svelte/reference/{CreateInfiniteQueryOptions.md => type-aliases/createinfinitequeryoptions.md} (92%) rename docs/framework/svelte/reference/{CreateInfiniteQueryResult.md => type-aliases/createinfinitequeryresult.md} (87%) rename docs/framework/svelte/reference/{CreateMutateAsyncFunction.md => type-aliases/createmutateasyncfunction.md} (89%) rename docs/framework/svelte/reference/{CreateMutateFunction.md => type-aliases/createmutatefunction.md} (90%) rename docs/framework/svelte/reference/{CreateMutationOptions.md => type-aliases/createmutationoptions.md} (90%) rename docs/framework/svelte/reference/{CreateMutationResult.md => type-aliases/createmutationresult.md} (89%) rename docs/framework/svelte/reference/{CreateQueryOptions.md => type-aliases/createqueryoptions.md} (90%) rename docs/framework/svelte/reference/{CreateQueryResult.md => type-aliases/createqueryresult.md} (86%) rename docs/framework/svelte/reference/{DefinedCreateBaseQueryResult.md => type-aliases/definedcreatebasequeryresult.md} (88%) rename docs/framework/svelte/reference/{DefinedCreateQueryResult.md => type-aliases/definedcreatequeryresult.md} (87%) rename docs/framework/svelte/reference/{DefinedInitialDataOptions.md => type-aliases/definedinitialdataoptions.md} (92%) rename docs/framework/svelte/reference/{MutationStateOptions.md => type-aliases/mutationstateoptions.md} (90%) create mode 100644 docs/framework/svelte/reference/type-aliases/queriesoptions.md create mode 100644 docs/framework/svelte/reference/type-aliases/queriesresults.md rename docs/framework/svelte/reference/{StoreOrVal.md => type-aliases/storeorval.md} (83%) rename docs/framework/svelte/reference/{UndefinedInitialDataOptions.md => type-aliases/undefinedinitialdataoptions.md} (91%) diff --git a/docs/config.json b/docs/config.json index 9acb50a2e0..24239e85e6 100644 --- a/docs/config.json +++ b/docs/config.json @@ -747,11 +747,11 @@ }, { "label": "Functions / createQuery", - "to": "framework/svelte/reference/createQuery" + "to": "framework/svelte/reference/functions/createquery" }, { "label": "Functions / createMutation", - "to": "framework/svelte/reference/createMutation" + "to": "framework/svelte/reference/functions/createmutation" } ] }, @@ -761,6 +761,14 @@ { "label": "Angular Reference", "to": "framework/angular/reference/index" + }, + { + "label": "Functions / injectQuery", + "to": "framework/angular/reference/functions/injectquery" + }, + { + "label": "Functions / injectMutation", + "to": "framework/angular/reference/functions/injectmutation" } ] } diff --git a/docs/framework/angular/reference/infiniteQueryOptions.md b/docs/framework/angular/reference/functions/infinitequeryoptions.md similarity index 66% rename from docs/framework/angular/reference/infiniteQueryOptions.md rename to docs/framework/angular/reference/functions/infinitequeryoptions.md index f26c21eb4e..9d76ed9456 100644 --- a/docs/framework/angular/reference/infiniteQueryOptions.md +++ b/docs/framework/angular/reference/functions/infinitequeryoptions.md @@ -52,19 +52,25 @@ The `queryKey` will be tagged with the type from `queryFn`. ### Parameters -• **options**: [`UndefinedInitialDataInfiniteOptions`](UndefinedInitialDataInfiniteOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`, `TPageParam`\> +• **options**: [`UndefinedInitialDataInfiniteOptions`](../type-aliases/undefinedinitialdatainfiniteoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`, `TPageParam`\> The infinite query options to tag with the type from `queryFn`. ### Returns -[`UndefinedInitialDataInfiniteOptions`](UndefinedInitialDataInfiniteOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`, `TPageParam`\> & `object` +[`UndefinedInitialDataInfiniteOptions`](../type-aliases/undefinedinitialdatainfiniteoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`, `TPageParam`\> & `object` The tagged infinite query options. +The tagged infinite query options. + +### Param + +The infinite query options to tag with the type from `queryFn`. + ### Defined in -[infinite-query-options.ts:59](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/infinite-query-options.ts#L59) +[infinite-query-options.ts:59](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/infinite-query-options.ts#L59) ## infiniteQueryOptions(options) @@ -105,16 +111,22 @@ The `queryKey` will be tagged with the type from `queryFn`. ### Parameters -• **options**: [`DefinedInitialDataInfiniteOptions`](DefinedInitialDataInfiniteOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`, `TPageParam`\> +• **options**: [`DefinedInitialDataInfiniteOptions`](../type-aliases/definedinitialdatainfiniteoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`, `TPageParam`\> The infinite query options to tag with the type from `queryFn`. ### Returns -[`DefinedInitialDataInfiniteOptions`](DefinedInitialDataInfiniteOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`, `TPageParam`\> & `object` +[`DefinedInitialDataInfiniteOptions`](../type-aliases/definedinitialdatainfiniteoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`, `TPageParam`\> & `object` The tagged infinite query options. +The tagged infinite query options. + +### Param + +The infinite query options to tag with the type from `queryFn`. + ### Defined in -[infinite-query-options.ts:91](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/infinite-query-options.ts#L91) +[infinite-query-options.ts:91](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/infinite-query-options.ts#L91) diff --git a/docs/framework/angular/reference/injectInfiniteQuery.md b/docs/framework/angular/reference/functions/injectinfinitequery.md similarity index 78% rename from docs/framework/angular/reference/injectInfiniteQuery.md rename to docs/framework/angular/reference/functions/injectinfinitequery.md index b013cb562d..225f71d041 100644 --- a/docs/framework/angular/reference/injectInfiniteQuery.md +++ b/docs/framework/angular/reference/functions/injectinfinitequery.md @@ -55,13 +55,23 @@ The Angular injector to use. ### Returns -[`CreateInfiniteQueryResult`](CreateInfiniteQueryResult.md)\<`TData`, `TError`\> +[`CreateInfiniteQueryResult`](../type-aliases/createinfinitequeryresult.md)\<`TData`, `TError`\> The infinite query result. +The infinite query result. + +### Param + +A function that returns infinite query options. + +### Param + +The Angular injector to use. + ### Defined in -[inject-infinite-query.ts:30](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-infinite-query.ts#L30) +[inject-infinite-query.ts:30](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-infinite-query.ts#L30) ## injectInfiniteQuery(optionsFn, injector) @@ -102,13 +112,23 @@ The Angular injector to use. ### Returns -[`DefinedCreateInfiniteQueryResult`](DefinedCreateInfiniteQueryResult.md)\<`TData`, `TError`\> +[`DefinedCreateInfiniteQueryResult`](../type-aliases/definedcreateinfinitequeryresult.md)\<`TData`, `TError`\> + +The infinite query result. The infinite query result. +### Param + +A function that returns infinite query options. + +### Param + +The Angular injector to use. + ### Defined in -[inject-infinite-query.ts:57](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-infinite-query.ts#L57) +[inject-infinite-query.ts:57](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-infinite-query.ts#L57) ## injectInfiniteQuery(optionsFn, injector) @@ -149,10 +169,20 @@ The Angular injector to use. ### Returns -[`CreateInfiniteQueryResult`](CreateInfiniteQueryResult.md)\<`TData`, `TError`\> +[`CreateInfiniteQueryResult`](../type-aliases/createinfinitequeryresult.md)\<`TData`, `TError`\> + +The infinite query result. The infinite query result. +### Param + +A function that returns infinite query options. + +### Param + +The Angular injector to use. + ### Defined in -[inject-infinite-query.ts:84](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-infinite-query.ts#L84) +[inject-infinite-query.ts:84](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-infinite-query.ts#L84) diff --git a/docs/framework/angular/reference/injectIsFetching.md b/docs/framework/angular/reference/functions/injectisfetching.md similarity index 91% rename from docs/framework/angular/reference/injectIsFetching.md rename to docs/framework/angular/reference/functions/injectisfetching.md index c998ea7a69..79a7335ba3 100644 --- a/docs/framework/angular/reference/injectIsFetching.md +++ b/docs/framework/angular/reference/functions/injectisfetching.md @@ -32,4 +32,4 @@ signal with number of loading or fetching queries. ## Defined in -[inject-is-fetching.ts:17](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-is-fetching.ts#L17) +[inject-is-fetching.ts:17](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-is-fetching.ts#L17) diff --git a/docs/framework/angular/reference/injectIsMutating.md b/docs/framework/angular/reference/functions/injectismutating.md similarity index 90% rename from docs/framework/angular/reference/injectIsMutating.md rename to docs/framework/angular/reference/functions/injectismutating.md index 1016bf049a..210fdf4d56 100644 --- a/docs/framework/angular/reference/injectIsMutating.md +++ b/docs/framework/angular/reference/functions/injectismutating.md @@ -31,4 +31,4 @@ signal with number of fetching mutations. ## Defined in -[inject-is-mutating.ts:16](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-is-mutating.ts#L16) +[inject-is-mutating.ts:16](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-is-mutating.ts#L16) diff --git a/docs/framework/angular/reference/injectMutation.md b/docs/framework/angular/reference/functions/injectmutation.md similarity index 75% rename from docs/framework/angular/reference/injectMutation.md rename to docs/framework/angular/reference/functions/injectmutation.md index c2dfacdaa5..f649b79e96 100644 --- a/docs/framework/angular/reference/injectMutation.md +++ b/docs/framework/angular/reference/functions/injectmutation.md @@ -38,10 +38,10 @@ The Angular injector to use. ## Returns -[`CreateMutationResult`](CreateMutationResult.md)\<`TData`, `TError`, `TVariables`, `TContext`\> +[`CreateMutationResult`](../type-aliases/createmutationresult.md)\<`TData`, `TError`, `TVariables`, `TContext`\> The mutation. ## Defined in -[inject-mutation.ts:38](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-mutation.ts#L38) +[inject-mutation.ts:38](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-mutation.ts#L38) diff --git a/docs/framework/angular/reference/injectMutationState.md b/docs/framework/angular/reference/functions/injectmutationstate.md similarity index 81% rename from docs/framework/angular/reference/injectMutationState.md rename to docs/framework/angular/reference/functions/injectmutationstate.md index c841b21b31..899067a3c6 100644 --- a/docs/framework/angular/reference/injectMutationState.md +++ b/docs/framework/angular/reference/functions/injectmutationstate.md @@ -24,7 +24,7 @@ Injects a signal that tracks the state of all mutations. A function that returns mutation state options. -• **options?**: [`InjectMutationStateOptions`](InjectMutationStateOptions.md) +• **options?**: [`InjectMutationStateOptions`](../interfaces/injectmutationstateoptions.md) The Angular injector to use. @@ -36,4 +36,4 @@ The signal that tracks the state of all mutations. ## Defined in -[inject-mutation-state.ts:53](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-mutation-state.ts#L53) +[inject-mutation-state.ts:53](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-mutation-state.ts#L53) diff --git a/docs/framework/angular/reference/injectQueries.md b/docs/framework/angular/reference/functions/injectqueries.md similarity index 94% rename from docs/framework/angular/reference/injectQueries.md rename to docs/framework/angular/reference/functions/injectqueries.md index c32d5279fa..89403c640d 100644 --- a/docs/framework/angular/reference/injectQueries.md +++ b/docs/framework/angular/reference/functions/injectqueries.md @@ -34,4 +34,4 @@ function injectQueries( ## Defined in -[inject-queries.ts:188](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-queries.ts#L188) +[inject-queries.ts:188](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-queries.ts#L188) diff --git a/docs/framework/angular/reference/injectQuery.md b/docs/framework/angular/reference/functions/injectquery.md similarity index 82% rename from docs/framework/angular/reference/injectQuery.md rename to docs/framework/angular/reference/functions/injectquery.md index dd6b18493a..aa0b3196bf 100644 --- a/docs/framework/angular/reference/injectQuery.md +++ b/docs/framework/angular/reference/functions/injectquery.md @@ -114,17 +114,31 @@ The Angular injector to use. ### Returns -[`DefinedCreateQueryResult`](DefinedCreateQueryResult.md)\<`TData`, `TError`\> +[`DefinedCreateQueryResult`](../type-aliases/definedcreatequeryresult.md)\<`TData`, `TError`\> The query result. +The query result. + +### Param + +A function that returns query options. + +### Param + +The Angular injector to use. + +### See + +https://tanstack.com/query/latest/docs/framework/angular/guides/queries + ### See https://tanstack.com/query/latest/docs/framework/angular/guides/queries ### Defined in -[inject-query.ts:53](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-query.ts#L53) +[inject-query.ts:53](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-query.ts#L53) ## injectQuery(optionsFn, injector) @@ -190,17 +204,31 @@ The Angular injector to use. ### Returns -[`CreateQueryResult`](CreateQueryResult.md)\<`TData`, `TError`\> +[`CreateQueryResult`](../type-aliases/createqueryresult.md)\<`TData`, `TError`\> + +The query result. The query result. +### Param + +A function that returns query options. + +### Param + +The Angular injector to use. + +### See + +https://tanstack.com/query/latest/docs/framework/angular/guides/queries + ### See https://tanstack.com/query/latest/docs/framework/angular/guides/queries ### Defined in -[inject-query.ts:102](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-query.ts#L102) +[inject-query.ts:102](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-query.ts#L102) ## injectQuery(optionsFn, injector) @@ -266,14 +294,28 @@ The Angular injector to use. ### Returns -[`CreateQueryResult`](CreateQueryResult.md)\<`TData`, `TError`\> +[`CreateQueryResult`](../type-aliases/createqueryresult.md)\<`TData`, `TError`\> + +The query result. The query result. +### Param + +A function that returns query options. + +### Param + +The Angular injector to use. + +### See + +https://tanstack.com/query/latest/docs/framework/angular/guides/queries + ### See https://tanstack.com/query/latest/docs/framework/angular/guides/queries ### Defined in -[inject-query.ts:151](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-query.ts#L151) +[inject-query.ts:151](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-query.ts#L151) diff --git a/docs/framework/angular/reference/injectQueryClient.md b/docs/framework/angular/reference/functions/injectqueryclient.md similarity index 88% rename from docs/framework/angular/reference/injectQueryClient.md rename to docs/framework/angular/reference/functions/injectqueryclient.md index 53da63baae..ebe9bc821c 100644 --- a/docs/framework/angular/reference/injectQueryClient.md +++ b/docs/framework/angular/reference/functions/injectqueryclient.md @@ -33,7 +33,7 @@ const queryClient = injectQueryClient() ### Defined in -[inject-query-client.ts:16](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-query-client.ts#L16) +[inject-query-client.ts:16](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-query-client.ts#L16) ## injectQueryClient(injectOptions) @@ -59,7 +59,7 @@ const queryClient = injectQueryClient() ### Defined in -[inject-query-client.ts:16](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-query-client.ts#L16) +[inject-query-client.ts:16](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-query-client.ts#L16) ## injectQueryClient(injectOptions) @@ -85,4 +85,4 @@ const queryClient = injectQueryClient() ### Defined in -[inject-query-client.ts:16](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-query-client.ts#L16) +[inject-query-client.ts:16](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-query-client.ts#L16) diff --git a/docs/framework/angular/reference/provideAngularQuery.md b/docs/framework/angular/reference/functions/provideangularquery.md similarity index 89% rename from docs/framework/angular/reference/provideAngularQuery.md rename to docs/framework/angular/reference/functions/provideangularquery.md index 8be6f5af0c..f6d84bb926 100644 --- a/docs/framework/angular/reference/provideAngularQuery.md +++ b/docs/framework/angular/reference/functions/provideangularquery.md @@ -61,4 +61,4 @@ https://tanstack.com/query/v5/docs/framework/angular/quick-start ## Defined in -[providers.ts:50](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/providers.ts#L50) +[providers.ts:50](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/providers.ts#L50) diff --git a/docs/framework/angular/reference/provideQueryClient.md b/docs/framework/angular/reference/functions/providequeryclient.md similarity index 84% rename from docs/framework/angular/reference/provideQueryClient.md rename to docs/framework/angular/reference/functions/providequeryclient.md index f9fbc7efaf..b7de8ecb87 100644 --- a/docs/framework/angular/reference/provideQueryClient.md +++ b/docs/framework/angular/reference/functions/providequeryclient.md @@ -9,7 +9,7 @@ title: provideQueryClient function provideQueryClient(value): Provider ``` -Usually [provideAngularQuery](provideAngularQuery.md) is used once to set up TanStack Query and the +Usually [provideAngularQuery](provideangularquery.md) is used once to set up TanStack Query and the [https://tanstack.com/query/latest/docs/reference/QueryClient|QueryClient](https://tanstack.com/query/latest/docs/reference/QueryClient|QueryClient) for the entire application. You can use `provideQueryClient` to provide a different `QueryClient` instance for a part of the application. @@ -24,4 +24,4 @@ different `QueryClient` instance for a part of the application. ## Defined in -[inject-query-client.ts:25](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-query-client.ts#L25) +[inject-query-client.ts:25](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-query-client.ts#L25) diff --git a/docs/framework/angular/reference/queryOptions.md b/docs/framework/angular/reference/functions/queryoptions.md similarity index 69% rename from docs/framework/angular/reference/queryOptions.md rename to docs/framework/angular/reference/functions/queryoptions.md index 2e682f238e..05f9cc0a10 100644 --- a/docs/framework/angular/reference/queryOptions.md +++ b/docs/framework/angular/reference/functions/queryoptions.md @@ -65,19 +65,25 @@ const data = queryClient.getQueryData(queryKey) ### Parameters -• **options**: [`UndefinedInitialDataOptions`](UndefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> +• **options**: [`UndefinedInitialDataOptions`](../type-aliases/undefinedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> The query options to tag with the type from `queryFn`. ### Returns -[`UndefinedInitialDataOptions`](UndefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> & `object` +[`UndefinedInitialDataOptions`](../type-aliases/undefinedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> & `object` The tagged query options. +The tagged query options. + +### Param + +The query options to tag with the type from `queryFn`. + ### Defined in -[query-options.ts:52](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/query-options.ts#L52) +[query-options.ts:52](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/query-options.ts#L52) ## queryOptions(options) @@ -117,16 +123,22 @@ const data = queryClient.getQueryData(queryKey) ### Parameters -• **options**: [`DefinedInitialDataOptions`](DefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> +• **options**: [`DefinedInitialDataOptions`](../type-aliases/definedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> The query options to tag with the type from `queryFn`. ### Returns -[`DefinedInitialDataOptions`](DefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> & `object` +[`DefinedInitialDataOptions`](../type-aliases/definedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> & `object` The tagged query options. +The tagged query options. + +### Param + +The query options to tag with the type from `queryFn`. + ### Defined in -[query-options.ts:85](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/query-options.ts#L85) +[query-options.ts:85](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/query-options.ts#L85) diff --git a/docs/framework/angular/reference/index.md b/docs/framework/angular/reference/index.md index cbfd308e11..a0f861def3 100644 --- a/docs/framework/angular/reference/index.md +++ b/docs/framework/angular/reference/index.md @@ -7,44 +7,44 @@ title: '@tanstack/angular-query-experimental' ## Interfaces -- [BaseMutationNarrowing](BaseMutationNarrowing.md) -- [BaseQueryNarrowing](BaseQueryNarrowing.md) -- [CreateBaseQueryOptions](CreateBaseQueryOptions.md) -- [CreateInfiniteQueryOptions](CreateInfiniteQueryOptions.md) -- [CreateMutationOptions](CreateMutationOptions.md) -- [CreateQueryOptions](CreateQueryOptions.md) -- [InjectMutationStateOptions](InjectMutationStateOptions.md) +- [BaseMutationNarrowing](interfaces/basemutationnarrowing.md) +- [BaseQueryNarrowing](interfaces/basequerynarrowing.md) +- [CreateBaseQueryOptions](interfaces/createbasequeryoptions.md) +- [CreateInfiniteQueryOptions](interfaces/createinfinitequeryoptions.md) +- [CreateMutationOptions](interfaces/createmutationoptions.md) +- [CreateQueryOptions](interfaces/createqueryoptions.md) +- [InjectMutationStateOptions](interfaces/injectmutationstateoptions.md) ## Type Aliases -- [CreateBaseMutationResult](CreateBaseMutationResult.md) -- [CreateBaseQueryResult](CreateBaseQueryResult.md) -- [CreateInfiniteQueryResult](CreateInfiniteQueryResult.md) -- [CreateMutateAsyncFunction](CreateMutateAsyncFunction.md) -- [CreateMutateFunction](CreateMutateFunction.md) -- [CreateMutationResult](CreateMutationResult.md) -- [CreateQueryResult](CreateQueryResult.md) -- [DefinedCreateInfiniteQueryResult](DefinedCreateInfiniteQueryResult.md) -- [DefinedCreateQueryResult](DefinedCreateQueryResult.md) -- [DefinedInitialDataInfiniteOptions](DefinedInitialDataInfiniteOptions.md) -- [DefinedInitialDataOptions](DefinedInitialDataOptions.md) -- [NonUndefinedGuard](NonUndefinedGuard.md) -- [QueriesOptions](QueriesOptions.md) -- [QueriesResults](QueriesResults.md) -- [UndefinedInitialDataInfiniteOptions](UndefinedInitialDataInfiniteOptions.md) -- [UndefinedInitialDataOptions](UndefinedInitialDataOptions.md) +- [CreateBaseMutationResult](type-aliases/createbasemutationresult.md) +- [CreateBaseQueryResult](type-aliases/createbasequeryresult.md) +- [CreateInfiniteQueryResult](type-aliases/createinfinitequeryresult.md) +- [CreateMutateAsyncFunction](type-aliases/createmutateasyncfunction.md) +- [CreateMutateFunction](type-aliases/createmutatefunction.md) +- [CreateMutationResult](type-aliases/createmutationresult.md) +- [CreateQueryResult](type-aliases/createqueryresult.md) +- [DefinedCreateInfiniteQueryResult](type-aliases/definedcreateinfinitequeryresult.md) +- [DefinedCreateQueryResult](type-aliases/definedcreatequeryresult.md) +- [DefinedInitialDataInfiniteOptions](type-aliases/definedinitialdatainfiniteoptions.md) +- [DefinedInitialDataOptions](type-aliases/definedinitialdataoptions.md) +- [NonUndefinedGuard](type-aliases/nonundefinedguard.md) +- [QueriesOptions](type-aliases/queriesoptions.md) +- [QueriesResults](type-aliases/queriesresults.md) +- [UndefinedInitialDataInfiniteOptions](type-aliases/undefinedinitialdatainfiniteoptions.md) +- [UndefinedInitialDataOptions](type-aliases/undefinedinitialdataoptions.md) ## Functions -- [infiniteQueryOptions](infiniteQueryOptions.md) -- [injectInfiniteQuery](injectInfiniteQuery.md) -- [injectIsFetching](injectIsFetching.md) -- [injectIsMutating](injectIsMutating.md) -- [injectMutation](injectMutation.md) -- [injectMutationState](injectMutationState.md) -- [injectQueries](injectQueries.md) -- [injectQuery](injectQuery.md) -- [injectQueryClient](injectQueryClient.md) -- [provideAngularQuery](provideAngularQuery.md) -- [provideQueryClient](provideQueryClient.md) -- [queryOptions](queryOptions.md) +- [infiniteQueryOptions](functions/infinitequeryoptions.md) +- [injectInfiniteQuery](functions/injectinfinitequery.md) +- [injectIsFetching](functions/injectisfetching.md) +- [injectIsMutating](functions/injectismutating.md) +- [injectMutation](functions/injectmutation.md) +- [injectMutationState](functions/injectmutationstate.md) +- [injectQueries](functions/injectqueries.md) +- [injectQuery](functions/injectquery.md) +- [injectQueryClient](functions/injectqueryclient.md) +- [provideAngularQuery](functions/provideangularquery.md) +- [provideQueryClient](functions/providequeryclient.md) +- [queryOptions](functions/queryoptions.md) diff --git a/docs/framework/angular/reference/BaseMutationNarrowing.md b/docs/framework/angular/reference/interfaces/basemutationnarrowing.md similarity index 57% rename from docs/framework/angular/reference/BaseMutationNarrowing.md rename to docs/framework/angular/reference/interfaces/basemutationnarrowing.md index b8d84d615d..96ddd7fa63 100644 --- a/docs/framework/angular/reference/BaseMutationNarrowing.md +++ b/docs/framework/angular/reference/interfaces/basemutationnarrowing.md @@ -25,7 +25,7 @@ isError: (this) => this is CreateMutationResult\> +• **this**: [`CreateMutationResult`](../type-aliases/createmutationresult.md)\<`TData`, `TError`, `TVariables`, `TContext`, `CreateStatusBasedMutationResult`\<`"error"` \| `"success"` \| `"pending"` \| `"idle"`, `TData`, `TError`, `TVariables`, `TContext`\>\> #### Returns @@ -33,7 +33,7 @@ isError: (this) => this is CreateMutationResult this is CreateMutationResult\> +• **this**: [`CreateMutationResult`](../type-aliases/createmutationresult.md)\<`TData`, `TError`, `TVariables`, `TContext`, `CreateStatusBasedMutationResult`\<`"error"` \| `"success"` \| `"pending"` \| `"idle"`, `TData`, `TError`, `TVariables`, `TContext`\>\> #### Returns @@ -53,7 +53,7 @@ isIdle: (this) => this is CreateMutationResult this is CreateMutationResult\> +• **this**: [`CreateMutationResult`](../type-aliases/createmutationresult.md)\<`TData`, `TError`, `TVariables`, `TContext`, `CreateStatusBasedMutationResult`\<`"error"` \| `"success"` \| `"pending"` \| `"idle"`, `TData`, `TError`, `TVariables`, `TContext`\>\> #### Returns @@ -73,7 +73,7 @@ isPending: (this) => this is CreateMutationResult this is CreateMutationResult\> +• **this**: [`CreateMutationResult`](../type-aliases/createmutationresult.md)\<`TData`, `TError`, `TVariables`, `TContext`, `CreateStatusBasedMutationResult`\<`"error"` \| `"success"` \| `"pending"` \| `"idle"`, `TData`, `TError`, `TVariables`, `TContext`\>\> #### Returns @@ -93,4 +93,4 @@ isSuccess: (this) => this is CreateMutationResult this is CreateBaseQueryResult\> +• **this**: [`CreateBaseQueryResult`](../type-aliases/createbasequeryresult.md)\<`TData`, `TError`, `QueryObserverResult`\<`TData`, `TError`\>\> #### Returns @@ -29,7 +29,7 @@ isError: (this) => this is CreateBaseQueryResult this is CreateBaseQueryResult\> +• **this**: [`CreateBaseQueryResult`](../type-aliases/createbasequeryresult.md)\<`TData`, `TError`, `QueryObserverResult`\<`TData`, `TError`\>\> #### Returns @@ -49,7 +49,7 @@ isPending: (this) => this is CreateBaseQueryResult this is CreateBaseQueryResult\> +• **this**: [`CreateBaseQueryResult`](../type-aliases/createbasequeryresult.md)\<`TData`, `TError`, `QueryObserverResult`\<`TData`, `TError`\>\> #### Returns @@ -69,4 +69,4 @@ isSuccess: (this) => this is CreateBaseQueryResult, `"suspense"`\> +- `OmitKeyof`\<[`CreateBaseQueryOptions`](createbasequeryoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryFnData`, `TQueryKey`\>, `"suspense"`\> ## Type Parameters diff --git a/docs/framework/angular/reference/InjectMutationStateOptions.md b/docs/framework/angular/reference/interfaces/injectmutationstateoptions.md similarity index 83% rename from docs/framework/angular/reference/InjectMutationStateOptions.md rename to docs/framework/angular/reference/interfaces/injectmutationstateoptions.md index 5ba65b1f9e..15fe330c5c 100644 --- a/docs/framework/angular/reference/InjectMutationStateOptions.md +++ b/docs/framework/angular/reference/interfaces/injectmutationstateoptions.md @@ -15,4 +15,4 @@ optional injector: Injector; #### Defined in -[inject-mutation-state.ts:43](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-mutation-state.ts#L43) +[inject-mutation-state.ts:43](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-mutation-state.ts#L43) diff --git a/docs/framework/angular/reference/CreateBaseMutationResult.md b/docs/framework/angular/reference/type-aliases/createbasemutationresult.md similarity index 82% rename from docs/framework/angular/reference/CreateBaseMutationResult.md rename to docs/framework/angular/reference/type-aliases/createbasemutationresult.md index 81a9913805..3cad41d423 100644 --- a/docs/framework/angular/reference/CreateBaseMutationResult.md +++ b/docs/framework/angular/reference/type-aliases/createbasemutationresult.md @@ -29,4 +29,4 @@ mutateAsync: CreateMutateAsyncFunction ## Defined in -[types.ts:198](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/types.ts#L198) +[types.ts:198](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/types.ts#L198) diff --git a/docs/framework/angular/reference/CreateBaseQueryResult.md b/docs/framework/angular/reference/type-aliases/createbasequeryresult.md similarity index 78% rename from docs/framework/angular/reference/CreateBaseQueryResult.md rename to docs/framework/angular/reference/type-aliases/createbasequeryresult.md index 75874bc14f..3870240677 100644 --- a/docs/framework/angular/reference/CreateBaseQueryResult.md +++ b/docs/framework/angular/reference/type-aliases/createbasequeryresult.md @@ -19,4 +19,4 @@ type CreateBaseQueryResult: BaseQueryNarrowing: MapToSignals: MutateFunct ## Defined in -[types.ts:188](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/types.ts#L188) +[types.ts:188](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/types.ts#L188) diff --git a/docs/framework/angular/reference/CreateMutateFunction.md b/docs/framework/angular/reference/type-aliases/createmutatefunction.md similarity index 80% rename from docs/framework/angular/reference/CreateMutateFunction.md rename to docs/framework/angular/reference/type-aliases/createmutatefunction.md index d045b870d3..4a8d6580dd 100644 --- a/docs/framework/angular/reference/CreateMutateFunction.md +++ b/docs/framework/angular/reference/type-aliases/createmutatefunction.md @@ -29,4 +29,4 @@ type CreateMutateFunction: (...args) => voi ## Defined in -[types.ts:176](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/types.ts#L176) +[types.ts:176](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/types.ts#L176) diff --git a/docs/framework/angular/reference/CreateMutationResult.md b/docs/framework/angular/reference/type-aliases/createmutationresult.md similarity index 77% rename from docs/framework/angular/reference/CreateMutationResult.md rename to docs/framework/angular/reference/type-aliases/createmutationresult.md index c242e766ee..7f52e747fb 100644 --- a/docs/framework/angular/reference/CreateMutationResult.md +++ b/docs/framework/angular/reference/type-aliases/createmutationresult.md @@ -19,8 +19,8 @@ type CreateMutationResult: BaseMuta • **TContext** = `unknown` -• **TState** = `CreateStatusBasedMutationResult`\<[`CreateBaseMutationResult`](CreateBaseMutationResult.md)\[`"status"`\], `TData`, `TError`, `TVariables`, `TContext`\> +• **TState** = `CreateStatusBasedMutationResult`\<[`CreateBaseMutationResult`](createbasemutationresult.md)\[`"status"`\], `TData`, `TError`, `TVariables`, `TContext`\> ## Defined in -[types.ts:292](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/types.ts#L292) +[types.ts:292](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/types.ts#L292) diff --git a/docs/framework/angular/reference/CreateQueryResult.md b/docs/framework/angular/reference/type-aliases/createqueryresult.md similarity index 70% rename from docs/framework/angular/reference/CreateQueryResult.md rename to docs/framework/angular/reference/type-aliases/createqueryresult.md index 2cc1ac2bd8..18b6952820 100644 --- a/docs/framework/angular/reference/CreateQueryResult.md +++ b/docs/framework/angular/reference/type-aliases/createqueryresult.md @@ -17,4 +17,4 @@ type CreateQueryResult: CreateBaseQueryResult; ## Defined in -[types.ts:126](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/types.ts#L126) +[types.ts:126](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/types.ts#L126) diff --git a/docs/framework/angular/reference/DefinedCreateInfiniteQueryResult.md b/docs/framework/angular/reference/type-aliases/definedcreateinfinitequeryresult.md similarity index 80% rename from docs/framework/angular/reference/DefinedCreateInfiniteQueryResult.md rename to docs/framework/angular/reference/type-aliases/definedcreateinfinitequeryresult.md index 88f5b4016f..5107554d67 100644 --- a/docs/framework/angular/reference/DefinedCreateInfiniteQueryResult.md +++ b/docs/framework/angular/reference/type-aliases/definedcreateinfinitequeryresult.md @@ -19,4 +19,4 @@ type DefinedCreateInfiniteQueryResult: MapToSignal ## Defined in -[types.ts:134](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/types.ts#L134) +[types.ts:134](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/types.ts#L134) diff --git a/docs/framework/angular/reference/DefinedInitialDataInfiniteOptions.md b/docs/framework/angular/reference/type-aliases/definedinitialdatainfiniteoptions.md similarity index 93% rename from docs/framework/angular/reference/DefinedInitialDataInfiniteOptions.md rename to docs/framework/angular/reference/type-aliases/definedinitialdatainfiniteoptions.md index df6672c34d..ad63b14f44 100644 --- a/docs/framework/angular/reference/DefinedInitialDataInfiniteOptions.md +++ b/docs/framework/angular/reference/type-aliases/definedinitialdatainfiniteoptions.md @@ -31,4 +31,4 @@ initialData: NonUndefinedGuard> | () => N ## Defined in -[infinite-query-options.ts:32](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/infinite-query-options.ts#L32) +[infinite-query-options.ts:32](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/infinite-query-options.ts#L32) diff --git a/docs/framework/angular/reference/DefinedInitialDataOptions.md b/docs/framework/angular/reference/type-aliases/definedinitialdataoptions.md similarity index 83% rename from docs/framework/angular/reference/DefinedInitialDataOptions.md rename to docs/framework/angular/reference/type-aliases/definedinitialdataoptions.md index 67f9338617..f4e8b6da59 100644 --- a/docs/framework/angular/reference/DefinedInitialDataOptions.md +++ b/docs/framework/angular/reference/type-aliases/definedinitialdataoptions.md @@ -29,4 +29,4 @@ initialData: NonUndefinedGuard | () => NonUndefinedGuard: T extends undefined ? never : T; ## Defined in -[types.ts:316](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/types.ts#L316) +[types.ts:316](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/types.ts#L316) diff --git a/docs/framework/angular/reference/QueriesOptions.md b/docs/framework/angular/reference/type-aliases/queriesoptions.md similarity index 88% rename from docs/framework/angular/reference/QueriesOptions.md rename to docs/framework/angular/reference/type-aliases/queriesoptions.md index b56da403c7..e21003d6f9 100644 --- a/docs/framework/angular/reference/QueriesOptions.md +++ b/docs/framework/angular/reference/type-aliases/queriesoptions.md @@ -21,4 +21,4 @@ QueriesOptions reducer recursively unwraps function arguments to infer/enforce t ## Defined in -[inject-queries.ts:108](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-queries.ts#L108) +[inject-queries.ts:108](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-queries.ts#L108) diff --git a/docs/framework/angular/reference/QueriesResults.md b/docs/framework/angular/reference/type-aliases/queriesresults.md similarity index 87% rename from docs/framework/angular/reference/QueriesResults.md rename to docs/framework/angular/reference/type-aliases/queriesresults.md index c892133971..7ff2e3ebd1 100644 --- a/docs/framework/angular/reference/QueriesResults.md +++ b/docs/framework/angular/reference/type-aliases/queriesresults.md @@ -21,4 +21,4 @@ QueriesResults reducer recursively maps type param to results ## Defined in -[inject-queries.ts:151](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/inject-queries.ts#L151) +[inject-queries.ts:151](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/inject-queries.ts#L151) diff --git a/docs/framework/angular/reference/UndefinedInitialDataInfiniteOptions.md b/docs/framework/angular/reference/type-aliases/undefinedinitialdatainfiniteoptions.md similarity index 92% rename from docs/framework/angular/reference/UndefinedInitialDataInfiniteOptions.md rename to docs/framework/angular/reference/type-aliases/undefinedinitialdatainfiniteoptions.md index 81b2508c91..b1bb260cec 100644 --- a/docs/framework/angular/reference/UndefinedInitialDataInfiniteOptions.md +++ b/docs/framework/angular/reference/type-aliases/undefinedinitialdatainfiniteoptions.md @@ -31,4 +31,4 @@ optional initialData: undefined; ## Defined in -[infinite-query-options.ts:12](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/infinite-query-options.ts#L12) +[infinite-query-options.ts:12](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/infinite-query-options.ts#L12) diff --git a/docs/framework/angular/reference/UndefinedInitialDataOptions.md b/docs/framework/angular/reference/type-aliases/undefinedinitialdataoptions.md similarity index 82% rename from docs/framework/angular/reference/UndefinedInitialDataOptions.md rename to docs/framework/angular/reference/type-aliases/undefinedinitialdataoptions.md index 3f3aab95f2..bf64cf110e 100644 --- a/docs/framework/angular/reference/UndefinedInitialDataOptions.md +++ b/docs/framework/angular/reference/type-aliases/undefinedinitialdataoptions.md @@ -29,4 +29,4 @@ optional initialData: undefined; ## Defined in -[query-options.ts:7](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/angular-query-experimental/src/query-options.ts#L7) +[query-options.ts:7](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/angular-query-experimental/src/query-options.ts#L7) diff --git a/docs/framework/svelte/reference/QueriesOptions.md b/docs/framework/svelte/reference/QueriesOptions.md deleted file mode 100644 index 2aefbcec95..0000000000 --- a/docs/framework/svelte/reference/QueriesOptions.md +++ /dev/null @@ -1,24 +0,0 @@ ---- -id: QueriesOptions -title: QueriesOptions ---- - -# Type Alias: QueriesOptions\ - -```ts -type QueriesOptions: TDepth["length"] extends MAXIMUM_DEPTH ? QueryObserverOptionsForCreateQueries[] : T extends [] ? [] : T extends [infer Head] ? [...TResult, GetOptions] : T extends [infer Head, ...(infer Tail)] ? QueriesOptions<[...Tail], [...TResult, GetOptions], [...TDepth, 1]> : ReadonlyArray extends T ? T : T extends QueryObserverOptionsForCreateQueries[] ? QueryObserverOptionsForCreateQueries[] : QueryObserverOptionsForCreateQueries[]; -``` - -QueriesOptions reducer recursively unwraps function arguments to infer/enforce type param - -## Type Parameters - -• **T** _extends_ `any`[] - -• **TResult** _extends_ `any`[] = [] - -• **TDepth** _extends_ `ReadonlyArray`\<`number`\> = [] - -## Defined in - -[packages/svelte-query/src/createQueries.ts:110](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/createQueries.ts#L110) diff --git a/docs/framework/svelte/reference/QueriesResults.md b/docs/framework/svelte/reference/QueriesResults.md deleted file mode 100644 index d6320eb192..0000000000 --- a/docs/framework/svelte/reference/QueriesResults.md +++ /dev/null @@ -1,24 +0,0 @@ ---- -id: QueriesResults -title: QueriesResults ---- - -# Type Alias: QueriesResults\ - -```ts -type QueriesResults: TDepth["length"] extends MAXIMUM_DEPTH ? QueryObserverResult[] : T extends [] ? [] : T extends [infer Head] ? [...TResult, GetResults] : T extends [infer Head, ...(infer Tail)] ? QueriesResults<[...Tail], [...TResult, GetResults], [...TDepth, 1]> : T extends QueryObserverOptionsForCreateQueries[] ? QueryObserverResult[] : QueryObserverResult[]; -``` - -QueriesResults reducer recursively maps type param to results - -## Type Parameters - -• **T** _extends_ `any`[] - -• **TResult** _extends_ `any`[] = [] - -• **TDepth** _extends_ `ReadonlyArray`\<`number`\> = [] - -## Defined in - -[packages/svelte-query/src/createQueries.ts:152](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/createQueries.ts#L152) diff --git a/docs/framework/svelte/reference/HydrationBoundary.md b/docs/framework/svelte/reference/classes/hydrationboundary.md similarity index 98% rename from docs/framework/svelte/reference/HydrationBoundary.md rename to docs/framework/svelte/reference/classes/hydrationboundary.md index 7c4f1012f0..9690e1a6d6 100644 --- a/docs/framework/svelte/reference/HydrationBoundary.md +++ b/docs/framework/svelte/reference/classes/hydrationboundary.md @@ -62,7 +62,7 @@ new HydrationBoundary(options): HydrationBoundary +[`HydrationBoundary`](hydrationboundary.md)\<`Props`, `Events`, `Slots`\> #### Overrides diff --git a/docs/framework/svelte/reference/createQueries.md b/docs/framework/svelte/reference/createQueries.md deleted file mode 100644 index bb00c13b1a..0000000000 --- a/docs/framework/svelte/reference/createQueries.md +++ /dev/null @@ -1,37 +0,0 @@ ---- -id: createQueries -title: createQueries ---- - -# Function: createQueries() - -```ts -function createQueries( - __namedParameters, - queryClient?, -): Readable -``` - -## Type Parameters - -• **T** _extends_ `any`[] - -• **TCombinedResult** = `T` _extends_ [] ? [] : `T` _extends_ [`Head`] ? [`GetResults`\<`Head`\>] : `T` _extends_ [`Head`, `...Tail[]`] ? [`...Tail[]`] _extends_ [] ? [] : [`...Tail[]`] _extends_ [`Head`] ? [`GetResults`\<`Head`\>, `GetResults`\<`Head`\>] : [`...Tail[]`] _extends_ [`Head`, `...Tail[]`] ? [`...Tail[]`] _extends_ [] ? [] : [`...Tail[]`] _extends_ [`Head`] ? [`GetResults`\<`Head`\>, `GetResults`\<`Head`\>, `GetResults`\<`Head`\>] : [`...Tail[]`] _extends_ [`Head`, `...Tail[]`] ? [`...(...)[]`] _extends_ [] ? [] : ... _extends_ ... ? ... : ... : [`...(...)[]`] _extends_ ...[] ? ...[] : ...[] : [`...Tail[]`] _extends_ `QueryObserverOptionsForCreateQueries`\<`TQueryFnData`, `TError`, `TData`, `any`\>[] ? `QueryObserverResult`\<`unknown` _extends_ `TData` ? `TQueryFnData` : `TData`, `unknown` _extends_ `TError` ? `Error` : `TError`\>[] : `QueryObserverResult`[] : `T` _extends_ `QueryObserverOptionsForCreateQueries`\<`TQueryFnData`, `TError`, `TData`, `any`\>[] ? `QueryObserverResult`\<`unknown` _extends_ `TData` ? `TQueryFnData` : `TData`, `unknown` _extends_ `TError` ? `Error` : `TError`\>[] : `QueryObserverResult`[] - -## Parameters - -• **\_\_namedParameters** - -• **\_\_namedParameters.combine?** - -• **\_\_namedParameters.queries?**: [`StoreOrVal`](StoreOrVal.md)\<[`...(T extends [] ? [] : T extends [Head] ? [GetOptions] : T extends [Head, ...Tail[]] ? [...Tail[]] extends [] ? [] : [...Tail[]] extends [Head] ? [GetOptions, GetOptions] : [...Tail[]] extends [Head, ...Tail[]] ? [...(...)[]] extends [] ? [] : (...) extends (...) ? (...) : (...) : readonly (...)[] extends [...(...)[]] ? [...(...)[]] : (...) extends (...) ? (...) : (...) : readonly unknown[] extends T ? T : T extends QueryObserverOptionsForCreateQueries[] ? QueryObserverOptionsForCreateQueries[] : QueryObserverOptionsForCreateQueries[])[]`]\> - -• **queryClient?**: `QueryClient` - -## Returns - -`Readable`\<`TCombinedResult`\> - -## Defined in - -[packages/svelte-query/src/createQueries.ts:186](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/createQueries.ts#L186) diff --git a/docs/framework/svelte/reference/createQuery.md b/docs/framework/svelte/reference/createQuery.md deleted file mode 100644 index 99716abfd4..0000000000 --- a/docs/framework/svelte/reference/createQuery.md +++ /dev/null @@ -1,72 +0,0 @@ ---- -id: createQuery -title: createQuery ---- - -# Function: createQuery() - -## createQuery(options, queryClient) - -```ts -function createQuery( - options, - queryClient?, -): CreateQueryResult -``` - -### Type Parameters - -• **TQueryFnData** = `unknown` - -• **TError** = `Error` - -• **TData** = `TQueryFnData` - -• **TQueryKey** _extends_ `QueryKey` = `QueryKey` - -### Parameters - -• **options**: [`StoreOrVal`](StoreOrVal.md)\<[`UndefinedInitialDataOptions`](UndefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\>\> - -• **queryClient?**: `QueryClient` - -### Returns - -[`CreateQueryResult`](CreateQueryResult.md)\<`TData`, `TError`\> - -### Defined in - -[packages/svelte-query/src/createQuery.ts:15](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/createQuery.ts#L15) - -## createQuery(options, queryClient) - -```ts -function createQuery( - options, - queryClient?, -): DefinedCreateQueryResult -``` - -### Type Parameters - -• **TQueryFnData** = `unknown` - -• **TError** = `Error` - -• **TData** = `TQueryFnData` - -• **TQueryKey** _extends_ `QueryKey` = `QueryKey` - -### Parameters - -• **options**: [`StoreOrVal`](StoreOrVal.md)\<[`DefinedInitialDataOptions`](DefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\>\> - -• **queryClient?**: `QueryClient` - -### Returns - -[`DefinedCreateQueryResult`](DefinedCreateQueryResult.md)\<`TData`, `TError`\> - -### Defined in - -[packages/svelte-query/src/createQuery.ts:27](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/createQuery.ts#L27) diff --git a/docs/framework/svelte/reference/createInfiniteQuery.md b/docs/framework/svelte/reference/functions/createinfinitequery.md similarity index 58% rename from docs/framework/svelte/reference/createInfiniteQuery.md rename to docs/framework/svelte/reference/functions/createinfinitequery.md index f7cde0fdb7..a067f73775 100644 --- a/docs/framework/svelte/reference/createInfiniteQuery.md +++ b/docs/framework/svelte/reference/functions/createinfinitequery.md @@ -29,14 +29,14 @@ function createInfiniteQuery< ## Parameters -• **options**: [`StoreOrVal`](StoreOrVal.md)\<[`CreateInfiniteQueryOptions`](CreateInfiniteQueryOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryFnData`, `TQueryKey`, `TPageParam`\>\> +• **options**: [`StoreOrVal`](../type-aliases/storeorval.md)\<[`CreateInfiniteQueryOptions`](../type-aliases/createinfinitequeryoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryFnData`, `TQueryKey`, `TPageParam`\>\> • **queryClient?**: `QueryClient` ## Returns -[`CreateInfiniteQueryResult`](CreateInfiniteQueryResult.md)\<`TData`, `TError`\> +[`CreateInfiniteQueryResult`](../type-aliases/createinfinitequeryresult.md)\<`TData`, `TError`\> ## Defined in -[packages/svelte-query/src/createInfiniteQuery.ts:16](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/createInfiniteQuery.ts#L16) +[packages/svelte-query/src/createInfiniteQuery.ts:16](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/createInfiniteQuery.ts#L16) diff --git a/docs/framework/svelte/reference/createMutation.md b/docs/framework/svelte/reference/functions/createmutation.md similarity index 61% rename from docs/framework/svelte/reference/createMutation.md rename to docs/framework/svelte/reference/functions/createmutation.md index 8fc780361a..ad11e8c6e9 100644 --- a/docs/framework/svelte/reference/createMutation.md +++ b/docs/framework/svelte/reference/functions/createmutation.md @@ -24,14 +24,14 @@ function createMutation( ## Parameters -• **options**: [`StoreOrVal`](StoreOrVal.md)\<[`CreateMutationOptions`](CreateMutationOptions.md)\<`TData`, `TError`, `TVariables`, `TContext`\>\> +• **options**: [`StoreOrVal`](../type-aliases/storeorval.md)\<[`CreateMutationOptions`](../type-aliases/createmutationoptions.md)\<`TData`, `TError`, `TVariables`, `TContext`\>\> • **queryClient?**: `QueryClient` ## Returns -[`CreateMutationResult`](CreateMutationResult.md)\<`TData`, `TError`, `TVariables`, `TContext`\> +[`CreateMutationResult`](../type-aliases/createmutationresult.md)\<`TData`, `TError`, `TVariables`, `TContext`\> ## Defined in -[packages/svelte-query/src/createMutation.ts:13](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/createMutation.ts#L13) +[packages/svelte-query/src/createMutation.ts:13](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/createMutation.ts#L13) diff --git a/docs/framework/svelte/reference/functions/createqueries.md b/docs/framework/svelte/reference/functions/createqueries.md new file mode 100644 index 0000000000..90a77b2a1c --- /dev/null +++ b/docs/framework/svelte/reference/functions/createqueries.md @@ -0,0 +1,37 @@ +--- +id: createQueries +title: createQueries +--- + +# Function: createQueries() + +```ts +function createQueries( + __namedParameters, + queryClient?, +): Readable +``` + +## Type Parameters + +• **T** _extends_ `any`[] + +• **TCombinedResult** = `T` _extends_ [] ? [] : `T` _extends_ [`Head`] ? [`GetCreateQueryResult`\<`Head`\>] : `T` _extends_ [`Head`, `...Tails[]`] ? [`...Tails[]`] _extends_ [] ? [] : [`...Tails[]`] _extends_ [`Head`] ? [`GetCreateQueryResult`\<`Head`\>, `GetCreateQueryResult`\<`Head`\>] : [`...Tails[]`] _extends_ [`Head`, `...Tails[]`] ? [`...Tails[]`] _extends_ [] ? [] : [`...Tails[]`] _extends_ [`Head`] ? [`GetCreateQueryResult`\<`Head`\>, `GetCreateQueryResult`\<`Head`\>, `GetCreateQueryResult`\<`Head`\>] : [`...Tails[]`] _extends_ [`Head`, `...Tails[]`] ? [`...(...)[]`] _extends_ [] ? [] : ... _extends_ ... ? ... : ... : [`...(...)[]`] _extends_ ...[] ? ...[] : ...[] : [`...Tails[]`] _extends_ `QueryObserverOptionsForCreateQueries`\<`TQueryFnData`, `TError`, `TData`, `any`\>[] ? `QueryObserverResult`\<`unknown` _extends_ `TData` ? `TQueryFnData` : `TData`, `unknown` _extends_ `TError` ? `Error` : `TError`\>[] : `QueryObserverResult`[] : `T` _extends_ `QueryObserverOptionsForCreateQueries`\<`TQueryFnData`, `TError`, `TData`, `any`\>[] ? `QueryObserverResult`\<`unknown` _extends_ `TData` ? `TQueryFnData` : `TData`, `unknown` _extends_ `TError` ? `Error` : `TError`\>[] : `QueryObserverResult`[] + +## Parameters + +• **\_\_namedParameters** + +• **\_\_namedParameters.combine?** + +• **\_\_namedParameters.queries?**: [`StoreOrVal`](../type-aliases/storeorval.md)\<[`...(T extends [] ? [] : T extends [Head] ? [GetQueryObserverOptionsForCreateQueries] : T extends [Head, ...Tails[]] ? [...Tails[]] extends [] ? [] : [...Tails[]] extends [Head] ? [GetQueryObserverOptionsForCreateQueries, GetQueryObserverOptionsForCreateQueries] : [...Tails[]] extends [Head, ...Tails[]] ? [...(...)[]] extends [] ? [] : (...) extends (...) ? (...) : (...) : readonly (...)[] extends [...(...)[]] ? [...(...)[]] : (...) extends (...) ? (...) : (...) : readonly unknown[] extends T ? T : T extends QueryObserverOptionsForCreateQueries[] ? QueryObserverOptionsForCreateQueries[] : QueryObserverOptionsForCreateQueries[])[]`]\> + +• **queryClient?**: `QueryClient` + +## Returns + +`Readable`\<`TCombinedResult`\> + +## Defined in + +[packages/svelte-query/src/createQueries.ts:205](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/createQueries.ts#L205) diff --git a/docs/framework/svelte/reference/functions/createquery.md b/docs/framework/svelte/reference/functions/createquery.md new file mode 100644 index 0000000000..605fbc1f99 --- /dev/null +++ b/docs/framework/svelte/reference/functions/createquery.md @@ -0,0 +1,105 @@ +--- +id: createQuery +title: createQuery +--- + +# Function: createQuery() + +## createQuery(options, queryClient) + +```ts +function createQuery( + options, + queryClient?, +): DefinedCreateQueryResult +``` + +### Type Parameters + +• **TQueryFnData** = `unknown` + +• **TError** = `Error` + +• **TData** = `TQueryFnData` + +• **TQueryKey** _extends_ `QueryKey` = `QueryKey` + +### Parameters + +• **options**: [`StoreOrVal`](../type-aliases/storeorval.md)\<[`DefinedInitialDataOptions`](../type-aliases/definedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\>\> + +• **queryClient?**: `QueryClient` + +### Returns + +[`DefinedCreateQueryResult`](../type-aliases/definedcreatequeryresult.md)\<`TData`, `TError`\> + +### Defined in + +[packages/svelte-query/src/createQuery.ts:15](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/createQuery.ts#L15) + +## createQuery(options, queryClient) + +```ts +function createQuery( + options, + queryClient?, +): CreateQueryResult +``` + +### Type Parameters + +• **TQueryFnData** = `unknown` + +• **TError** = `Error` + +• **TData** = `TQueryFnData` + +• **TQueryKey** _extends_ `QueryKey` = `QueryKey` + +### Parameters + +• **options**: [`StoreOrVal`](../type-aliases/storeorval.md)\<[`UndefinedInitialDataOptions`](../type-aliases/undefinedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\>\> + +• **queryClient?**: `QueryClient` + +### Returns + +[`CreateQueryResult`](../type-aliases/createqueryresult.md)\<`TData`, `TError`\> + +### Defined in + +[packages/svelte-query/src/createQuery.ts:27](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/createQuery.ts#L27) + +## createQuery(options, queryClient) + +```ts +function createQuery( + options, + queryClient?, +): CreateQueryResult +``` + +### Type Parameters + +• **TQueryFnData** = `unknown` + +• **TError** = `Error` + +• **TData** = `TQueryFnData` + +• **TQueryKey** _extends_ `QueryKey` = `QueryKey` + +### Parameters + +• **options**: [`StoreOrVal`](../type-aliases/storeorval.md)\<[`CreateQueryOptions`](../type-aliases/createqueryoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\>\> + +• **queryClient?**: `QueryClient` + +### Returns + +[`CreateQueryResult`](../type-aliases/createqueryresult.md)\<`TData`, `TError`\> + +### Defined in + +[packages/svelte-query/src/createQuery.ts:39](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/createQuery.ts#L39) diff --git a/docs/framework/svelte/reference/getIsRestoringContext.md b/docs/framework/svelte/reference/functions/getisrestoringcontext.md similarity index 85% rename from docs/framework/svelte/reference/getIsRestoringContext.md rename to docs/framework/svelte/reference/functions/getisrestoringcontext.md index 4b80fe9a1a..22aa563796 100644 --- a/docs/framework/svelte/reference/getIsRestoringContext.md +++ b/docs/framework/svelte/reference/functions/getisrestoringcontext.md @@ -17,4 +17,4 @@ Retrieves a `isRestoring` from Svelte's context ## Defined in -[packages/svelte-query/src/context.ts:28](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/context.ts#L28) +[packages/svelte-query/src/context.ts:28](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/context.ts#L28) diff --git a/docs/framework/svelte/reference/getQueryClientContext.md b/docs/framework/svelte/reference/functions/getqueryclientcontext.md similarity index 84% rename from docs/framework/svelte/reference/getQueryClientContext.md rename to docs/framework/svelte/reference/functions/getqueryclientcontext.md index ddbdf7c21d..f311a473f6 100644 --- a/docs/framework/svelte/reference/getQueryClientContext.md +++ b/docs/framework/svelte/reference/functions/getqueryclientcontext.md @@ -17,4 +17,4 @@ Retrieves a Client from Svelte's context ## Defined in -[packages/svelte-query/src/context.ts:9](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/context.ts#L9) +[packages/svelte-query/src/context.ts:9](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/context.ts#L9) diff --git a/docs/framework/svelte/reference/infiniteQueryOptions.md b/docs/framework/svelte/reference/functions/infinitequeryoptions.md similarity index 58% rename from docs/framework/svelte/reference/infiniteQueryOptions.md rename to docs/framework/svelte/reference/functions/infinitequeryoptions.md index 7fb5dee1fe..3e9a0c5b4b 100644 --- a/docs/framework/svelte/reference/infiniteQueryOptions.md +++ b/docs/framework/svelte/reference/functions/infinitequeryoptions.md @@ -38,12 +38,12 @@ function infiniteQueryOptions< ## Parameters -• **options**: [`CreateInfiniteQueryOptions`](CreateInfiniteQueryOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryFnData`, `TQueryKey`, `TPageParam`\> +• **options**: [`CreateInfiniteQueryOptions`](../type-aliases/createinfinitequeryoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryFnData`, `TQueryKey`, `TPageParam`\> ## Returns -[`CreateInfiniteQueryOptions`](CreateInfiniteQueryOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryFnData`, `TQueryKey`, `TPageParam`\> +[`CreateInfiniteQueryOptions`](../type-aliases/createinfinitequeryoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryFnData`, `TQueryKey`, `TPageParam`\> ## Defined in -[packages/svelte-query/src/infiniteQueryOptions.ts:4](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/infiniteQueryOptions.ts#L4) +[packages/svelte-query/src/infiniteQueryOptions.ts:4](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/infiniteQueryOptions.ts#L4) diff --git a/docs/framework/svelte/reference/queryOptions.md b/docs/framework/svelte/reference/functions/queryoptions.md similarity index 61% rename from docs/framework/svelte/reference/queryOptions.md rename to docs/framework/svelte/reference/functions/queryoptions.md index bca91eee2a..d499202669 100644 --- a/docs/framework/svelte/reference/queryOptions.md +++ b/docs/framework/svelte/reference/functions/queryoptions.md @@ -10,7 +10,7 @@ title: queryOptions ```ts function queryOptions( options, -): UndefinedInitialDataOptions & object +): DefinedInitialDataOptions & object ``` ### Type Parameters @@ -25,22 +25,22 @@ function queryOptions( ### Parameters -• **options**: [`UndefinedInitialDataOptions`](UndefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> +• **options**: [`DefinedInitialDataOptions`](../type-aliases/definedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> ### Returns -[`UndefinedInitialDataOptions`](UndefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> & `object` +[`DefinedInitialDataOptions`](../type-aliases/definedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> & `object` ### Defined in -[packages/svelte-query/src/queryOptions.ts:26](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/queryOptions.ts#L26) +[packages/svelte-query/src/queryOptions.ts:26](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/queryOptions.ts#L26) ## queryOptions(options) ```ts function queryOptions( options, -): DefinedInitialDataOptions & object +): UndefinedInitialDataOptions & object ``` ### Type Parameters @@ -55,12 +55,12 @@ function queryOptions( ### Parameters -• **options**: [`DefinedInitialDataOptions`](DefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> +• **options**: [`UndefinedInitialDataOptions`](../type-aliases/undefinedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> ### Returns -[`DefinedInitialDataOptions`](DefinedInitialDataOptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> & `object` +[`UndefinedInitialDataOptions`](../type-aliases/undefinedinitialdataoptions.md)\<`TQueryFnData`, `TError`, `TData`, `TQueryKey`\> & `object` ### Defined in -[packages/svelte-query/src/queryOptions.ts:37](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/queryOptions.ts#L37) +[packages/svelte-query/src/queryOptions.ts:37](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/queryOptions.ts#L37) diff --git a/docs/framework/svelte/reference/setIsRestoringContext.md b/docs/framework/svelte/reference/functions/setisrestoringcontext.md similarity index 86% rename from docs/framework/svelte/reference/setIsRestoringContext.md rename to docs/framework/svelte/reference/functions/setisrestoringcontext.md index 9c0e8441e4..0ab290bf09 100644 --- a/docs/framework/svelte/reference/setIsRestoringContext.md +++ b/docs/framework/svelte/reference/functions/setisrestoringcontext.md @@ -21,4 +21,4 @@ Sets a `isRestoring` on Svelte's context ## Defined in -[packages/svelte-query/src/context.ts:40](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/context.ts#L40) +[packages/svelte-query/src/context.ts:40](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/context.ts#L40) diff --git a/docs/framework/svelte/reference/setQueryClientContext.md b/docs/framework/svelte/reference/functions/setqueryclientcontext.md similarity index 85% rename from docs/framework/svelte/reference/setQueryClientContext.md rename to docs/framework/svelte/reference/functions/setqueryclientcontext.md index e39855484e..4a4ce300b2 100644 --- a/docs/framework/svelte/reference/setQueryClientContext.md +++ b/docs/framework/svelte/reference/functions/setqueryclientcontext.md @@ -21,4 +21,4 @@ Sets a QueryClient on Svelte's context ## Defined in -[packages/svelte-query/src/context.ts:21](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/context.ts#L21) +[packages/svelte-query/src/context.ts:21](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/context.ts#L21) diff --git a/docs/framework/svelte/reference/useHydrate.md b/docs/framework/svelte/reference/functions/usehydrate.md similarity index 85% rename from docs/framework/svelte/reference/useHydrate.md rename to docs/framework/svelte/reference/functions/usehydrate.md index 6ead965980..c4abb97e0d 100644 --- a/docs/framework/svelte/reference/useHydrate.md +++ b/docs/framework/svelte/reference/functions/usehydrate.md @@ -23,4 +23,4 @@ function useHydrate(state?, options?, queryClient?): void ## Defined in -[packages/svelte-query/src/useHydrate.ts:8](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/useHydrate.ts#L8) +[packages/svelte-query/src/useHydrate.ts:8](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/useHydrate.ts#L8) diff --git a/docs/framework/svelte/reference/useIsFetching.md b/docs/framework/svelte/reference/functions/useisfetching.md similarity index 86% rename from docs/framework/svelte/reference/useIsFetching.md rename to docs/framework/svelte/reference/functions/useisfetching.md index 0969e18e50..fbfd0d55bf 100644 --- a/docs/framework/svelte/reference/useIsFetching.md +++ b/docs/framework/svelte/reference/functions/useisfetching.md @@ -21,4 +21,4 @@ function useIsFetching(filters?, queryClient?): Readable ## Defined in -[packages/svelte-query/src/useIsFetching.ts:10](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/useIsFetching.ts#L10) +[packages/svelte-query/src/useIsFetching.ts:10](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/useIsFetching.ts#L10) diff --git a/docs/framework/svelte/reference/useIsMutating.md b/docs/framework/svelte/reference/functions/useismutating.md similarity index 86% rename from docs/framework/svelte/reference/useIsMutating.md rename to docs/framework/svelte/reference/functions/useismutating.md index 94bc295e50..2e05ae3218 100644 --- a/docs/framework/svelte/reference/useIsMutating.md +++ b/docs/framework/svelte/reference/functions/useismutating.md @@ -21,4 +21,4 @@ function useIsMutating(filters?, queryClient?): Readable ## Defined in -[packages/svelte-query/src/useIsMutating.ts:10](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/useIsMutating.ts#L10) +[packages/svelte-query/src/useIsMutating.ts:10](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/useIsMutating.ts#L10) diff --git a/docs/framework/svelte/reference/useIsRestoring.md b/docs/framework/svelte/reference/functions/useisrestoring.md similarity index 82% rename from docs/framework/svelte/reference/useIsRestoring.md rename to docs/framework/svelte/reference/functions/useisrestoring.md index d9eacc2ffb..4cd72cfab8 100644 --- a/docs/framework/svelte/reference/useIsRestoring.md +++ b/docs/framework/svelte/reference/functions/useisrestoring.md @@ -15,4 +15,4 @@ function useIsRestoring(): Readable ## Defined in -[packages/svelte-query/src/useIsRestoring.ts:4](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/useIsRestoring.ts#L4) +[packages/svelte-query/src/useIsRestoring.ts:4](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/useIsRestoring.ts#L4) diff --git a/docs/framework/svelte/reference/useMutationState.md b/docs/framework/svelte/reference/functions/usemutationstate.md similarity index 66% rename from docs/framework/svelte/reference/useMutationState.md rename to docs/framework/svelte/reference/functions/usemutationstate.md index 9a5b3ac26c..83de5455e7 100644 --- a/docs/framework/svelte/reference/useMutationState.md +++ b/docs/framework/svelte/reference/functions/usemutationstate.md @@ -15,7 +15,7 @@ function useMutationState(options, queryClient?): Readable ## Parameters -• **options**: [`MutationStateOptions`](MutationStateOptions.md)\<`TResult`\> = `{}` +• **options**: [`MutationStateOptions`](../type-aliases/mutationstateoptions.md)\<`TResult`\> = `{}` • **queryClient?**: `QueryClient` @@ -25,4 +25,4 @@ function useMutationState(options, queryClient?): Readable ## Defined in -[packages/svelte-query/src/useMutationState.ts:24](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/useMutationState.ts#L24) +[packages/svelte-query/src/useMutationState.ts:24](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/useMutationState.ts#L24) diff --git a/docs/framework/svelte/reference/useQueryClient.md b/docs/framework/svelte/reference/functions/usequeryclient.md similarity index 84% rename from docs/framework/svelte/reference/useQueryClient.md rename to docs/framework/svelte/reference/functions/usequeryclient.md index c21290de18..e6f169c143 100644 --- a/docs/framework/svelte/reference/useQueryClient.md +++ b/docs/framework/svelte/reference/functions/usequeryclient.md @@ -19,4 +19,4 @@ function useQueryClient(queryClient?): QueryClient ## Defined in -[packages/svelte-query/src/useQueryClient.ts:4](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/useQueryClient.ts#L4) +[packages/svelte-query/src/useQueryClient.ts:4](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/useQueryClient.ts#L4) diff --git a/docs/framework/svelte/reference/index.md b/docs/framework/svelte/reference/index.md index 05c9d0834b..8b50592d89 100644 --- a/docs/framework/svelte/reference/index.md +++ b/docs/framework/svelte/reference/index.md @@ -9,49 +9,49 @@ title: '@tanstack/svelte-query' ### QueryClientProvider -Renames and re-exports [HydrationBoundary](HydrationBoundary.md) +Renames and re-exports [HydrationBoundary](classes/hydrationboundary.md) ## Classes -- [HydrationBoundary](HydrationBoundary.md) +- [HydrationBoundary](classes/hydrationboundary.md) ## Type Aliases -- [CreateBaseMutationResult](CreateBaseMutationResult.md) -- [CreateBaseQueryOptions](CreateBaseQueryOptions.md) -- [CreateBaseQueryResult](CreateBaseQueryResult.md) -- [CreateInfiniteQueryOptions](CreateInfiniteQueryOptions.md) -- [CreateInfiniteQueryResult](CreateInfiniteQueryResult.md) -- [CreateMutateAsyncFunction](CreateMutateAsyncFunction.md) -- [CreateMutateFunction](CreateMutateFunction.md) -- [CreateMutationOptions](CreateMutationOptions.md) -- [CreateMutationResult](CreateMutationResult.md) -- [CreateQueryOptions](CreateQueryOptions.md) -- [CreateQueryResult](CreateQueryResult.md) -- [DefinedCreateBaseQueryResult](DefinedCreateBaseQueryResult.md) -- [DefinedCreateQueryResult](DefinedCreateQueryResult.md) -- [DefinedInitialDataOptions](DefinedInitialDataOptions.md) -- [MutationStateOptions](MutationStateOptions.md) -- [QueriesOptions](QueriesOptions.md) -- [QueriesResults](QueriesResults.md) -- [StoreOrVal](StoreOrVal.md) -- [UndefinedInitialDataOptions](UndefinedInitialDataOptions.md) +- [CreateBaseMutationResult](type-aliases/createbasemutationresult.md) +- [CreateBaseQueryOptions](type-aliases/createbasequeryoptions.md) +- [CreateBaseQueryResult](type-aliases/createbasequeryresult.md) +- [CreateInfiniteQueryOptions](type-aliases/createinfinitequeryoptions.md) +- [CreateInfiniteQueryResult](type-aliases/createinfinitequeryresult.md) +- [CreateMutateAsyncFunction](type-aliases/createmutateasyncfunction.md) +- [CreateMutateFunction](type-aliases/createmutatefunction.md) +- [CreateMutationOptions](type-aliases/createmutationoptions.md) +- [CreateMutationResult](type-aliases/createmutationresult.md) +- [CreateQueryOptions](type-aliases/createqueryoptions.md) +- [CreateQueryResult](type-aliases/createqueryresult.md) +- [DefinedCreateBaseQueryResult](type-aliases/definedcreatebasequeryresult.md) +- [DefinedCreateQueryResult](type-aliases/definedcreatequeryresult.md) +- [DefinedInitialDataOptions](type-aliases/definedinitialdataoptions.md) +- [MutationStateOptions](type-aliases/mutationstateoptions.md) +- [QueriesOptions](type-aliases/queriesoptions.md) +- [QueriesResults](type-aliases/queriesresults.md) +- [StoreOrVal](type-aliases/storeorval.md) +- [UndefinedInitialDataOptions](type-aliases/undefinedinitialdataoptions.md) ## Functions -- [createInfiniteQuery](createInfiniteQuery.md) -- [createMutation](createMutation.md) -- [createQueries](createQueries.md) -- [createQuery](createQuery.md) -- [getIsRestoringContext](getIsRestoringContext.md) -- [getQueryClientContext](getQueryClientContext.md) -- [infiniteQueryOptions](infiniteQueryOptions.md) -- [queryOptions](queryOptions.md) -- [setIsRestoringContext](setIsRestoringContext.md) -- [setQueryClientContext](setQueryClientContext.md) -- [useHydrate](useHydrate.md) -- [useIsFetching](useIsFetching.md) -- [useIsMutating](useIsMutating.md) -- [useIsRestoring](useIsRestoring.md) -- [useMutationState](useMutationState.md) -- [useQueryClient](useQueryClient.md) +- [createInfiniteQuery](functions/createinfinitequery.md) +- [createMutation](functions/createmutation.md) +- [createQueries](functions/createqueries.md) +- [createQuery](functions/createquery.md) +- [getIsRestoringContext](functions/getisrestoringcontext.md) +- [getQueryClientContext](functions/getqueryclientcontext.md) +- [infiniteQueryOptions](functions/infinitequeryoptions.md) +- [queryOptions](functions/queryoptions.md) +- [setIsRestoringContext](functions/setisrestoringcontext.md) +- [setQueryClientContext](functions/setqueryclientcontext.md) +- [useHydrate](functions/usehydrate.md) +- [useIsFetching](functions/useisfetching.md) +- [useIsMutating](functions/useismutating.md) +- [useIsRestoring](functions/useisrestoring.md) +- [useMutationState](functions/usemutationstate.md) +- [useQueryClient](functions/usequeryclient.md) diff --git a/docs/framework/svelte/reference/CreateBaseMutationResult.md b/docs/framework/svelte/reference/type-aliases/createbasemutationresult.md similarity index 91% rename from docs/framework/svelte/reference/CreateBaseMutationResult.md rename to docs/framework/svelte/reference/type-aliases/createbasemutationresult.md index bf36c6b7af..750c599d80 100644 --- a/docs/framework/svelte/reference/CreateBaseMutationResult.md +++ b/docs/framework/svelte/reference/type-aliases/createbasemutationresult.md @@ -29,4 +29,4 @@ mutateAsync: CreateMutateAsyncFunction ## Defined in -[packages/svelte-query/src/types.ts:113](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L113) +[packages/svelte-query/src/types.ts:113](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L113) diff --git a/docs/framework/svelte/reference/CreateBaseQueryOptions.md b/docs/framework/svelte/reference/type-aliases/createbasequeryoptions.md similarity index 91% rename from docs/framework/svelte/reference/CreateBaseQueryOptions.md rename to docs/framework/svelte/reference/type-aliases/createbasequeryoptions.md index c0f3ed4155..8a1967c124 100644 --- a/docs/framework/svelte/reference/CreateBaseQueryOptions.md +++ b/docs/framework/svelte/reference/type-aliases/createbasequeryoptions.md @@ -25,4 +25,4 @@ Options for createBaseQuery ## Defined in -[packages/svelte-query/src/types.ts:23](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L23) +[packages/svelte-query/src/types.ts:23](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L23) diff --git a/docs/framework/svelte/reference/CreateBaseQueryResult.md b/docs/framework/svelte/reference/type-aliases/createbasequeryresult.md similarity index 87% rename from docs/framework/svelte/reference/CreateBaseQueryResult.md rename to docs/framework/svelte/reference/type-aliases/createbasequeryresult.md index c8cfe86b32..01d19e64ea 100644 --- a/docs/framework/svelte/reference/CreateBaseQueryResult.md +++ b/docs/framework/svelte/reference/type-aliases/createbasequeryresult.md @@ -19,4 +19,4 @@ Result from createBaseQuery ## Defined in -[packages/svelte-query/src/types.ts:32](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L32) +[packages/svelte-query/src/types.ts:32](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L32) diff --git a/docs/framework/svelte/reference/CreateInfiniteQueryOptions.md b/docs/framework/svelte/reference/type-aliases/createinfinitequeryoptions.md similarity index 92% rename from docs/framework/svelte/reference/CreateInfiniteQueryOptions.md rename to docs/framework/svelte/reference/type-aliases/createinfinitequeryoptions.md index 1ccc6e62a5..e248532a85 100644 --- a/docs/framework/svelte/reference/CreateInfiniteQueryOptions.md +++ b/docs/framework/svelte/reference/type-aliases/createinfinitequeryoptions.md @@ -27,4 +27,4 @@ Options for createInfiniteQuery ## Defined in -[packages/svelte-query/src/types.ts:52](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L52) +[packages/svelte-query/src/types.ts:52](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L52) diff --git a/docs/framework/svelte/reference/CreateInfiniteQueryResult.md b/docs/framework/svelte/reference/type-aliases/createinfinitequeryresult.md similarity index 87% rename from docs/framework/svelte/reference/CreateInfiniteQueryResult.md rename to docs/framework/svelte/reference/type-aliases/createinfinitequeryresult.md index 9cf61260aa..4027388adc 100644 --- a/docs/framework/svelte/reference/CreateInfiniteQueryResult.md +++ b/docs/framework/svelte/reference/type-aliases/createinfinitequeryresult.md @@ -19,4 +19,4 @@ Result from createInfiniteQuery ## Defined in -[packages/svelte-query/src/types.ts:69](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L69) +[packages/svelte-query/src/types.ts:69](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L69) diff --git a/docs/framework/svelte/reference/CreateMutateAsyncFunction.md b/docs/framework/svelte/reference/type-aliases/createmutateasyncfunction.md similarity index 89% rename from docs/framework/svelte/reference/CreateMutateAsyncFunction.md rename to docs/framework/svelte/reference/type-aliases/createmutateasyncfunction.md index 1002beeda0..01567a772e 100644 --- a/docs/framework/svelte/reference/CreateMutateAsyncFunction.md +++ b/docs/framework/svelte/reference/type-aliases/createmutateasyncfunction.md @@ -21,4 +21,4 @@ type CreateMutateAsyncFunction: MutateFunct ## Defined in -[packages/svelte-query/src/types.ts:106](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L106) +[packages/svelte-query/src/types.ts:106](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L106) diff --git a/docs/framework/svelte/reference/CreateMutateFunction.md b/docs/framework/svelte/reference/type-aliases/createmutatefunction.md similarity index 90% rename from docs/framework/svelte/reference/CreateMutateFunction.md rename to docs/framework/svelte/reference/type-aliases/createmutatefunction.md index d5bd8e33c3..18230411ef 100644 --- a/docs/framework/svelte/reference/CreateMutateFunction.md +++ b/docs/framework/svelte/reference/type-aliases/createmutatefunction.md @@ -29,4 +29,4 @@ type CreateMutateFunction: (...args) => voi ## Defined in -[packages/svelte-query/src/types.ts:97](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L97) +[packages/svelte-query/src/types.ts:97](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L97) diff --git a/docs/framework/svelte/reference/CreateMutationOptions.md b/docs/framework/svelte/reference/type-aliases/createmutationoptions.md similarity index 90% rename from docs/framework/svelte/reference/CreateMutationOptions.md rename to docs/framework/svelte/reference/type-aliases/createmutationoptions.md index 184f3fc92f..c091bb44db 100644 --- a/docs/framework/svelte/reference/CreateMutationOptions.md +++ b/docs/framework/svelte/reference/type-aliases/createmutationoptions.md @@ -23,4 +23,4 @@ Options for createMutation ## Defined in -[packages/svelte-query/src/types.ts:87](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L87) +[packages/svelte-query/src/types.ts:87](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L87) diff --git a/docs/framework/svelte/reference/CreateMutationResult.md b/docs/framework/svelte/reference/type-aliases/createmutationresult.md similarity index 89% rename from docs/framework/svelte/reference/CreateMutationResult.md rename to docs/framework/svelte/reference/type-aliases/createmutationresult.md index b155a39d3e..f0cc9f62c7 100644 --- a/docs/framework/svelte/reference/CreateMutationResult.md +++ b/docs/framework/svelte/reference/type-aliases/createmutationresult.md @@ -23,4 +23,4 @@ Result from createMutation ## Defined in -[packages/svelte-query/src/types.ts:126](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L126) +[packages/svelte-query/src/types.ts:126](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L126) diff --git a/docs/framework/svelte/reference/CreateQueryOptions.md b/docs/framework/svelte/reference/type-aliases/createqueryoptions.md similarity index 90% rename from docs/framework/svelte/reference/CreateQueryOptions.md rename to docs/framework/svelte/reference/type-aliases/createqueryoptions.md index 518834fcec..0f24070104 100644 --- a/docs/framework/svelte/reference/CreateQueryOptions.md +++ b/docs/framework/svelte/reference/type-aliases/createqueryoptions.md @@ -23,4 +23,4 @@ Options for createQuery ## Defined in -[packages/svelte-query/src/types.ts:38](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L38) +[packages/svelte-query/src/types.ts:38](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L38) diff --git a/docs/framework/svelte/reference/CreateQueryResult.md b/docs/framework/svelte/reference/type-aliases/createqueryresult.md similarity index 86% rename from docs/framework/svelte/reference/CreateQueryResult.md rename to docs/framework/svelte/reference/type-aliases/createqueryresult.md index f8d14053fe..f57f253fea 100644 --- a/docs/framework/svelte/reference/CreateQueryResult.md +++ b/docs/framework/svelte/reference/type-aliases/createqueryresult.md @@ -19,4 +19,4 @@ Result from createQuery ## Defined in -[packages/svelte-query/src/types.ts:46](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L46) +[packages/svelte-query/src/types.ts:46](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L46) diff --git a/docs/framework/svelte/reference/DefinedCreateBaseQueryResult.md b/docs/framework/svelte/reference/type-aliases/definedcreatebasequeryresult.md similarity index 88% rename from docs/framework/svelte/reference/DefinedCreateBaseQueryResult.md rename to docs/framework/svelte/reference/type-aliases/definedcreatebasequeryresult.md index 1275d1ab97..1c4afda88a 100644 --- a/docs/framework/svelte/reference/DefinedCreateBaseQueryResult.md +++ b/docs/framework/svelte/reference/type-aliases/definedcreatebasequeryresult.md @@ -19,4 +19,4 @@ Options for createBaseQuery with initialData ## Defined in -[packages/svelte-query/src/types.ts:75](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L75) +[packages/svelte-query/src/types.ts:75](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L75) diff --git a/docs/framework/svelte/reference/DefinedCreateQueryResult.md b/docs/framework/svelte/reference/type-aliases/definedcreatequeryresult.md similarity index 87% rename from docs/framework/svelte/reference/DefinedCreateQueryResult.md rename to docs/framework/svelte/reference/type-aliases/definedcreatequeryresult.md index f6f2c309cd..7f360dc680 100644 --- a/docs/framework/svelte/reference/DefinedCreateQueryResult.md +++ b/docs/framework/svelte/reference/type-aliases/definedcreatequeryresult.md @@ -19,4 +19,4 @@ Options for createQuery with initialData ## Defined in -[packages/svelte-query/src/types.ts:81](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L81) +[packages/svelte-query/src/types.ts:81](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L81) diff --git a/docs/framework/svelte/reference/DefinedInitialDataOptions.md b/docs/framework/svelte/reference/type-aliases/definedinitialdataoptions.md similarity index 92% rename from docs/framework/svelte/reference/DefinedInitialDataOptions.md rename to docs/framework/svelte/reference/type-aliases/definedinitialdataoptions.md index 7c093250a5..95a0613537 100644 --- a/docs/framework/svelte/reference/DefinedInitialDataOptions.md +++ b/docs/framework/svelte/reference/type-aliases/definedinitialdataoptions.md @@ -29,4 +29,4 @@ initialData: NonUndefinedGuard | () => NonUndefinedGuard TResult; ## Defined in -[packages/svelte-query/src/types.ts:140](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L140) +[packages/svelte-query/src/types.ts:140](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L140) diff --git a/docs/framework/svelte/reference/type-aliases/queriesoptions.md b/docs/framework/svelte/reference/type-aliases/queriesoptions.md new file mode 100644 index 0000000000..0f6fe1097b --- /dev/null +++ b/docs/framework/svelte/reference/type-aliases/queriesoptions.md @@ -0,0 +1,24 @@ +--- +id: QueriesOptions +title: QueriesOptions +--- + +# Type Alias: QueriesOptions\ + +```ts +type QueriesOptions: TDepth["length"] extends MAXIMUM_DEPTH ? QueryObserverOptionsForCreateQueries[] : T extends [] ? [] : T extends [infer Head] ? [...TResults, GetQueryObserverOptionsForCreateQueries] : T extends [infer Head, ...(infer Tails)] ? QueriesOptions<[...Tails], [...TResults, GetQueryObserverOptionsForCreateQueries], [...TDepth, 1]> : ReadonlyArray extends T ? T : T extends QueryObserverOptionsForCreateQueries[] ? QueryObserverOptionsForCreateQueries[] : QueryObserverOptionsForCreateQueries[]; +``` + +QueriesOptions reducer recursively unwraps function arguments to infer/enforce type param + +## Type Parameters + +• **T** _extends_ `any`[] + +• **TResults** _extends_ `any`[] = [] + +• **TDepth** _extends_ `ReadonlyArray`\<`number`\> = [] + +## Defined in + +[packages/svelte-query/src/createQueries.ts:129](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/createQueries.ts#L129) diff --git a/docs/framework/svelte/reference/type-aliases/queriesresults.md b/docs/framework/svelte/reference/type-aliases/queriesresults.md new file mode 100644 index 0000000000..7ce41d896f --- /dev/null +++ b/docs/framework/svelte/reference/type-aliases/queriesresults.md @@ -0,0 +1,24 @@ +--- +id: QueriesResults +title: QueriesResults +--- + +# Type Alias: QueriesResults\ + +```ts +type QueriesResults: TDepth["length"] extends MAXIMUM_DEPTH ? QueryObserverResult[] : T extends [] ? [] : T extends [infer Head] ? [...TResults, GetCreateQueryResult] : T extends [infer Head, ...(infer Tails)] ? QueriesResults<[...Tails], [...TResults, GetCreateQueryResult], [...TDepth, 1]> : T extends QueryObserverOptionsForCreateQueries[] ? QueryObserverResult[] : QueryObserverResult[]; +``` + +QueriesResults reducer recursively maps type param to results + +## Type Parameters + +• **T** _extends_ `any`[] + +• **TResults** _extends_ `any`[] = [] + +• **TDepth** _extends_ `ReadonlyArray`\<`number`\> = [] + +## Defined in + +[packages/svelte-query/src/createQueries.ts:171](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/createQueries.ts#L171) diff --git a/docs/framework/svelte/reference/StoreOrVal.md b/docs/framework/svelte/reference/type-aliases/storeorval.md similarity index 83% rename from docs/framework/svelte/reference/StoreOrVal.md rename to docs/framework/svelte/reference/type-aliases/storeorval.md index ae6a6b54fc..7f7c5d5125 100644 --- a/docs/framework/svelte/reference/StoreOrVal.md +++ b/docs/framework/svelte/reference/type-aliases/storeorval.md @@ -17,4 +17,4 @@ Allows a type to be either the base object or a store of that object ## Defined in -[packages/svelte-query/src/types.ts:20](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/types.ts#L20) +[packages/svelte-query/src/types.ts:20](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/types.ts#L20) diff --git a/docs/framework/svelte/reference/UndefinedInitialDataOptions.md b/docs/framework/svelte/reference/type-aliases/undefinedinitialdataoptions.md similarity index 91% rename from docs/framework/svelte/reference/UndefinedInitialDataOptions.md rename to docs/framework/svelte/reference/type-aliases/undefinedinitialdataoptions.md index 8607b37866..de13b3d802 100644 --- a/docs/framework/svelte/reference/UndefinedInitialDataOptions.md +++ b/docs/framework/svelte/reference/type-aliases/undefinedinitialdataoptions.md @@ -29,4 +29,4 @@ optional initialData: undefined; ## Defined in -[packages/svelte-query/src/queryOptions.ts:4](https://github.com/TanStack/query/blob/27861961bbb36e9bc25fcd45cff21b5645f02f9b/packages/svelte-query/src/queryOptions.ts#L4) +[packages/svelte-query/src/queryOptions.ts:4](https://github.com/TanStack/query/blob/dac5da5416b82b0be38a8fb34dde1fc6670f0a59/packages/svelte-query/src/queryOptions.ts#L4) diff --git a/package.json b/package.json index 932801b615..9550a09787 100644 --- a/package.json +++ b/package.json @@ -41,7 +41,7 @@ "@cspell/eslint-plugin": "^8.9.1", "@eslint-react/eslint-plugin": "^1.5.16", "@solidjs/testing-library": "^0.8.8", - "@tanstack/config": "^0.11.0", + "@tanstack/config": "^0.11.1", "@testing-library/jest-dom": "^6.4.6", "@testing-library/react": "^16.0.0", "@types/eslint": "^8.56.10", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index a7dda5fb31..79ed9bbed3 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -28,8 +28,8 @@ importers: specifier: ^0.8.8 version: 0.8.8(@solidjs/router@0.13.3(solid-js@1.8.17))(solid-js@1.8.17) '@tanstack/config': - specifier: ^0.11.0 - version: 0.11.0(@types/node@20.14.10)(esbuild@0.19.11)(eslint@8.57.0)(rollup@4.14.1)(typescript@5.3.3)(vite@5.3.3(@types/node@20.14.10)(less@4.2.0)(sass@1.71.1)(terser@5.29.1)) + specifier: ^0.11.1 + version: 0.11.1(@types/node@20.14.10)(esbuild@0.19.11)(eslint@8.57.0)(rollup@4.14.1)(typescript@5.3.3)(vite@5.3.3(@types/node@20.14.10)(less@4.2.0)(sass@1.71.1)(terser@5.29.1)) '@testing-library/jest-dom': specifier: ^6.4.6 version: 6.4.6(vitest@2.0.3(@types/node@20.14.10)(jsdom@24.1.0)(less@4.2.0)(sass@1.71.1)(terser@5.29.1)) @@ -6166,8 +6166,8 @@ packages: '@swc/helpers@0.5.5': resolution: {integrity: sha512-KGYxvIOXcceOAbEk4bi/dVLEK9z8sZ0uBB3Il5b1rhfClSpcX0yfRO0KmTkqR2cnQDymwLB+25ZyMzICg/cm/A==} - '@tanstack/config@0.11.0': - resolution: {integrity: sha512-NKm06kFaIr+DErIjWhJLhG1DhaCOzpe85FztxtdK29Spp95DwXqp+6oEWYVfJgenweWfzK87kjahh5Za/i4Pfw==} + '@tanstack/config@0.11.1': + resolution: {integrity: sha512-P/U2ANQZMGpd6uBiVarY+SEVzCM50BOBV+C9c2pUZbMm3gtZN0a2LzX0fT0DutkeX3TsR5ogCw0ohxGzE4GcWw==} engines: {node: '>=18'} hasBin: true @@ -22498,7 +22498,7 @@ snapshots: '@swc/counter': 0.1.3 tslib: 2.6.2 - '@tanstack/config@0.11.0(@types/node@20.14.10)(esbuild@0.19.11)(eslint@8.57.0)(rollup@4.14.1)(typescript@5.3.3)(vite@5.3.3(@types/node@20.14.10)(less@4.2.0)(sass@1.71.1)(terser@5.29.1))': + '@tanstack/config@0.11.1(@types/node@20.14.10)(esbuild@0.19.11)(eslint@8.57.0)(rollup@4.14.1)(typescript@5.3.3)(vite@5.3.3(@types/node@20.14.10)(less@4.2.0)(sass@1.71.1)(terser@5.29.1))': dependencies: '@commitlint/parse': 19.0.3 '@eslint/js': 8.57.0 @@ -26471,7 +26471,7 @@ snapshots: eslint-plugin-import-x@3.0.1(eslint@8.57.0)(typescript@5.3.3): dependencies: '@rtsao/scc': 1.1.0 - '@typescript-eslint/utils': 7.16.1(eslint@8.57.0)(typescript@5.3.3) + '@typescript-eslint/utils': 7.17.0(eslint@8.57.0)(typescript@5.3.3) debug: 4.3.5(supports-color@6.1.0) doctrine: 3.0.0 eslint: 8.57.0