From 85c78c05df1d02d5b966ad28dac33a7ab56794ca Mon Sep 17 00:00:00 2001 From: SeanCassiere <33615041+SeanCassiere@users.noreply.github.com> Date: Tue, 9 Apr 2024 11:05:55 +1200 Subject: [PATCH 1/3] docs(react): top-level relative navigation --- docs/framework/react/installation.md | 2 +- docs/framework/react/overview.md | 2 +- .../react/plugins/createAsyncStoragePersister.md | 2 +- docs/framework/react/typescript.md | 8 ++++---- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/docs/framework/react/installation.md b/docs/framework/react/installation.md index acf9f8f3416..46862e7d6d5 100644 --- a/docs/framework/react/installation.md +++ b/docs/framework/react/installation.md @@ -54,7 +54,7 @@ Opera >= 77 ### Recommendations -It is recommended to also use our [ESLint Plugin Query](./eslint/eslint-plugin-query) to help you catch bugs and inconsistencies while you code. You can install it via: +It is recommended to also use our [ESLint Plugin Query](../../../eslint/eslint-plugin-query) to help you catch bugs and inconsistencies while you code. You can install it via: ```bash $ npm i -D @tanstack/eslint-plugin-query diff --git a/docs/framework/react/overview.md b/docs/framework/react/overview.md index 1f205b58c69..a4e806d4bd2 100644 --- a/docs/framework/react/overview.md +++ b/docs/framework/react/overview.md @@ -96,6 +96,6 @@ function Example() { ## You talked me into it, so what now? - Consider taking the official [React Query Course](https://query.gg?s=tanstack) (or buying it for your whole team!) -- Learn React Query at your own pace with our amazingly thorough [Walkthrough Guide](./installation) and [API Reference](../useQuery) +- Learn React Query at your own pace with our amazingly thorough [Walkthrough Guide](../installation) and [API Reference](../reference/useQuery) [//]: # 'Materials' diff --git a/docs/framework/react/plugins/createAsyncStoragePersister.md b/docs/framework/react/plugins/createAsyncStoragePersister.md index 37a07eb10e3..b0dfe9c735f 100644 --- a/docs/framework/react/plugins/createAsyncStoragePersister.md +++ b/docs/framework/react/plugins/createAsyncStoragePersister.md @@ -34,7 +34,7 @@ bun add @tanstack/query-async-storage-persister @tanstack/react-query-persist-cl - Import the `createAsyncStoragePersister` function - Create a new asyncStoragePersister - you can pass any `storage` to it that adheres to the `AsyncStorage` interface - the example below uses the async-storage from React Native -- Wrap your app by using [`PersistQueryClientProvider`](../persistQueryClient.md#persistqueryclientprovider) component. +- Wrap your app by using [`PersistQueryClientProvider`](../persistQueryClient#persistqueryclientprovider) component. ```tsx import AsyncStorage from '@react-native-async-storage/async-storage' diff --git a/docs/framework/react/typescript.md b/docs/framework/react/typescript.md index add86f41d4c..a5a7726064d 100644 --- a/docs/framework/react/typescript.md +++ b/docs/framework/react/typescript.md @@ -157,7 +157,7 @@ const { error } = useQuery({ queryKey: ['groups'], queryFn: fetchGroups }) ### Registering global Meta -Similarly to registering a [global error type](#registering-a-global-error) you can also register a global `Meta` type. This ensures the optional `meta` field on [queries](../useQuery.md) and [mutations](../useMutation.md) stays consistent and is type-safe. Note that the registered type must extend `Record` so that `meta` remains an object. +Similarly to registering a [global error type](#registering-a-global-error) you can also register a global `Meta` type. This ensures the optional `meta` field on [queries](../reference/useQuery) and [mutations](../reference/useMutation) stays consistent and is type-safe. Note that the registered type must extend `Record` so that `meta` remains an object. ```ts import '@tanstack/react-query' @@ -223,12 +223,12 @@ const data = queryClient.getQueryData(['groups']) ## Further Reading -For tips and tricks around type inference, have a look at [React Query and TypeScript](../tkdodos-blog#6-react-query-and-typescript) from -the Community Resources. To find out how to get the best possible type-safety, you can read [Type-safe React Query](../tkdodos-blog#19-type-safe-react-query). +For tips and tricks around type inference, have a look at [React Query and TypeScript](../community/tkdodos-blog#6-react-query-and-typescript) from +the Community Resources. To find out how to get the best possible type-safety, you can read [Type-safe React Query](../community/tkdodos-blog#19-type-safe-react-query). [//]: # 'Materials' ## Typesafe disabling of queries using `skipToken` If you are using TypeScript, you can use the `skipToken` to disable a query. This is useful when you want to disable a query based on a condition, but you still want to keep the query to be type safe. -Read more about it in the [Disabling Queries](../disabling-queries) guide. +Read more about it in the [Disabling Queries](../guides/disabling-queries) guide. From 01c1d82252d8a70b77cabba68c300bed074f56c5 Mon Sep 17 00:00:00 2001 From: SeanCassiere <33615041+SeanCassiere@users.noreply.github.com> Date: Tue, 9 Apr 2024 11:14:28 +1200 Subject: [PATCH 2/3] docs(vue): top-level relative navigation --- docs/framework/vue/overview.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/framework/vue/overview.md b/docs/framework/vue/overview.md index 40e614e3769..31c8da66ffc 100644 --- a/docs/framework/vue/overview.md +++ b/docs/framework/vue/overview.md @@ -11,6 +11,6 @@ replace: { 'React': 'Vue', 'react-query': 'vue-query' } ## You talked me into it, so what now? -- Learn Vue Query at your own pace with our amazingly thorough [Walkthrough Guide](./installation) and [API Reference](../useQuery) +- Learn Vue Query at your own pace with our amazingly thorough [Walkthrough Guide](../installation) and [API Reference](../reference/useQuery) [//]: # 'Materials' From 2692b92ad4dc531c84124ec161f541b9b0632ac5 Mon Sep 17 00:00:00 2001 From: SeanCassiere <33615041+SeanCassiere@users.noreply.github.com> Date: Tue, 9 Apr 2024 11:16:48 +1200 Subject: [PATCH 3/3] docs(svelte): top-level relative navigation --- docs/framework/svelte/overview.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/framework/svelte/overview.md b/docs/framework/svelte/overview.md index 6b5125cd303..89e60dcfdac 100644 --- a/docs/framework/svelte/overview.md +++ b/docs/framework/svelte/overview.md @@ -71,4 +71,4 @@ Svelte Query offers useful functions and components that will make managing serv Svelte Query offers an API similar to React Query, but there are some key differences to be mindful of. - Many of the functions in Svelte Query return a Svelte store. To access values on these stores reactively, you need to prefix the store with a `$`. You can learn more about Svelte stores [here](https://svelte.dev/tutorial/writable-stores). -- If your query or mutation depends on variables, you must use a store for the options. You can read more about this [here](./reactivity). +- If your query or mutation depends on variables, you must use a store for the options. You can read more about this [here](../reactivity).