Skip to content

Commit 8bfa77b

Browse files
authored
docs(react-query): fix incorrect link in documentation (#8699)
* docs(react-query): fix incorrect paths in documentation The documentation contained incorrect file paths. Fixed the incorrect paths to match the actual directory structure. * docs(react-query): fixed incorrect relative path (./ -> ../)
1 parent 0511c82 commit 8bfa77b

14 files changed

+29
-29
lines changed

docs/framework/react/reference/infiniteQueryOptions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ infiniteQueryOptions({
1212

1313
**Options**
1414

15-
You can generally pass everything to `infiniteQueryOptions` that you can also pass to [`useInfiniteQuery`](../useInfiniteQuery). Some options will have no effect when then forwarded to a function like `queryClient.prefetchInfiniteQuery`, but TypeScript will still be fine with those excess properties.
15+
You can generally pass everything to `infiniteQueryOptions` that you can also pass to [`useInfiniteQuery`](../reference/useInfiniteQuery). Some options will have no effect when then forwarded to a function like `queryClient.prefetchInfiniteQuery`, but TypeScript will still be fine with those excess properties.
1616

1717
- `queryKey: QueryKey`
1818
- **Required**

docs/framework/react/reference/queryOptions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ queryOptions({
1212

1313
**Options**
1414

15-
You can generally pass everything to `queryOptions` that you can also pass to [`useQuery`](../useQuery). Some options will have no effect when then forwarded to a function like `queryClient.prefetchQuery`, but TypeScript will still be fine with those excess properties.
15+
You can generally pass everything to `queryOptions` that you can also pass to [`useQuery`](../reference/useQuery). Some options will have no effect when then forwarded to a function like `queryClient.prefetchQuery`, but TypeScript will still be fine with those excess properties.
1616

1717
- `queryKey: QueryKey`
1818
- **Required**

docs/framework/react/reference/useInfiniteQuery.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,12 @@ const {
2727

2828
**Options**
2929

30-
The options for `useInfiniteQuery` are identical to the [`useQuery` hook](../useQuery) with the addition of the following:
30+
The options for `useInfiniteQuery` are identical to the [`useQuery` hook](../reference/useQuery) with the addition of the following:
3131

3232
- `queryFn: (context: QueryFunctionContext) => Promise<TData>`
33-
- **Required, but only if no default query function has been defined** [`defaultQueryFn`](../../guides/default-query-function)
33+
- **Required, but only if no default query function has been defined** [`defaultQueryFn`](../guides/default-query-function)
3434
- The function that the query will use to request data.
35-
- Receives a [QueryFunctionContext](../../guides/query-functions#queryfunctioncontext)
35+
- Receives a [QueryFunctionContext](../guides/query-functions#queryfunctioncontext)
3636
- Must return a promise that will either resolve data or throw an error.
3737
- `initialPageParam: TPageParam`
3838
- **Required**
@@ -55,7 +55,7 @@ The options for `useInfiniteQuery` are identical to the [`useQuery` hook](../use
5555

5656
**Returns**
5757

58-
The returned properties for `useInfiniteQuery` are identical to the [`useQuery` hook](../useQuery), with the addition of the following properties and a small difference in `isRefetching` and `isRefetchError`:
58+
The returned properties for `useInfiniteQuery` are identical to the [`useQuery` hook](../reference/useQuery), with the addition of the following properties and a small difference in `isRefetching` and `isRefetchError`:
5959

6060
- `data.pages: TData[]`
6161
- Array containing all pages.

docs/framework/react/reference/useIsFetching.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const isFetchingPosts = useIsFetching({ queryKey: ['posts'] })
1515

1616
**Options**
1717

18-
- `filters?: QueryFilters`: [Query Filters](../../guides/filters#query-filters)
18+
- `filters?: QueryFilters`: [Query Filters](../guides/filters#query-filters)
1919
- `queryClient?: QueryClient`,
2020
- Use this to use a custom QueryClient. Otherwise, the one from the nearest context will be used.
2121

docs/framework/react/reference/useIsMutating.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const isMutatingPosts = useIsMutating({ mutationKey: ['posts'] })
1515

1616
**Options**
1717

18-
- `filters?: MutationFilters`: [Mutation Filters](../../guides/filters#mutation-filters)
18+
- `filters?: MutationFilters`: [Mutation Filters](../guides/filters#mutation-filters)
1919
- `queryClient?: QueryClient`,
2020
- Use this to use a custom QueryClient. Otherwise, the one from the nearest context will be used.
2121

docs/framework/react/reference/useMutation.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ mutate(variables, {
6262
- `networkMode: 'online' | 'always' | 'offlineFirst'`
6363
- Optional
6464
- defaults to `'online'`
65-
- see [Network Mode](../../guides/network-mode) for more information.
65+
- see [Network Mode](../guides/network-mode) for more information.
6666
- `onMutate: (variables: TVariables) => Promise<TContext | void> | TContext | void`
6767
- Optional
6868
- This function will fire before the mutation function is fired and is passed the same variables the mutation function would receive
@@ -137,7 +137,7 @@ mutate(variables, {
137137
- `isIdle`, `isPending`, `isSuccess`, `isError`: boolean variables derived from `status`
138138
- `isPaused: boolean`
139139
- will be `true` if the mutation has been `paused`
140-
- see [Network Mode](../../guides/network-mode) for more information.
140+
- see [Network Mode](../guides/network-mode) for more information.
141141
- `data: undefined | unknown`
142142
- Defaults to `undefined`
143143
- The last successfully resolved data for the mutation.

docs/framework/react/reference/useMutationState.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ const latest = data[data.length - 1]
6969
**Options**
7070

7171
- `options`
72-
- `filters?: MutationFilters`: [Mutation Filters](../../guides/filters#mutation-filters)
72+
- `filters?: MutationFilters`: [Mutation Filters](../guides/filters#mutation-filters)
7373
- `select?: (mutation: Mutation) => TResult`
7474
- Use this to transform the mutation state.
7575
- `queryClient?: QueryClient`,

docs/framework/react/reference/usePrefetchInfiniteQuery.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ usePrefetchInfiniteQuery(options)
99

1010
**Options**
1111

12-
You can pass everything to `usePrefetchInfiniteQuery` that you can pass to [`queryClient.prefetchInfiniteQuery`](../../../../reference/QueryClient#queryclientprefetchinfinitequery). Remember that some of them are required as below:
12+
You can pass everything to `usePrefetchInfiniteQuery` that you can pass to [`queryClient.prefetchInfiniteQuery`](../../../reference/QueryClient#queryclientprefetchinfinitequery). Remember that some of them are required as below:
1313

1414
- `queryKey: QueryKey`
1515

@@ -18,7 +18,7 @@ You can pass everything to `usePrefetchInfiniteQuery` that you can pass to [`que
1818

1919
- `queryFn: (context: QueryFunctionContext) => Promise<TData>`
2020

21-
- **Required, but only if no default query function has been defined** See [Default Query Function](../../guides/default-query-function) for more information.
21+
- **Required, but only if no default query function has been defined** See [Default Query Function](../guides/default-query-function) for more information.
2222

2323
- `initialPageParam: TPageParam`
2424

@@ -34,4 +34,4 @@ You can pass everything to `usePrefetchInfiniteQuery` that you can pass to [`que
3434

3535
- **Returns**
3636

37-
The `usePrefetchInfiniteQuery` does not return anything, it should be used just to fire a prefetch during render, before a suspense boundary that wraps a component that uses [`useSuspenseInfiniteQuery`](../useSuspenseInfiniteQuery)
37+
The `usePrefetchInfiniteQuery` does not return anything, it should be used just to fire a prefetch during render, before a suspense boundary that wraps a component that uses [`useSuspenseInfiniteQuery`](../reference/useSuspenseInfiniteQuery)

docs/framework/react/reference/usePrefetchQuery.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,16 @@ usePrefetchQuery(options)
99

1010
**Options**
1111

12-
You can pass everything to `usePrefetchQuery` that you can pass to [`queryClient.prefetchQuery`](../../../../reference/QueryClient#queryclientprefetchquery). Remember that some of them are required as below:
12+
You can pass everything to `usePrefetchQuery` that you can pass to [`queryClient.prefetchQuery`](../../../reference/QueryClient#queryclientprefetchquery). Remember that some of them are required as below:
1313

1414
- `queryKey: QueryKey`
1515

1616
- **Required**
1717
- The query key to prefetch during render
1818

1919
- `queryFn: (context: QueryFunctionContext) => Promise<TData>`
20-
- **Required, but only if no default query function has been defined** See [Default Query Function](../../guides/default-query-function) for more information.
20+
- **Required, but only if no default query function has been defined** See [Default Query Function](../guides/default-query-function) for more information.
2121

2222
**Returns**
2323

24-
The `usePrefetchQuery` does not return anything, it should be used just to fire a prefetch during render, before a suspense boundary that wraps a component that uses [`useSuspenseQuery`](../useSuspenseQuery).
24+
The `usePrefetchQuery` does not return anything, it should be used just to fire a prefetch during render, before a suspense boundary that wraps a component that uses [`useSuspenseQuery`](../reference/useSuspenseQuery).

docs/framework/react/reference/useQueries.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const results = useQueries({
1818

1919
**Options**
2020

21-
The `useQueries` hook accepts an options object with a **queries** key whose value is an array with query option objects identical to the [`useQuery` hook](../useQuery) (excluding the `queryClient` option - because the `QueryClient` can be passed in on the top level).
21+
The `useQueries` hook accepts an options object with a **queries** key whose value is an array with query option objects identical to the [`useQuery` hook](../reference/useQuery) (excluding the `queryClient` option - because the `QueryClient` can be passed in on the top level).
2222

2323
- `queryClient?: QueryClient`
2424
- Use this to provide a custom QueryClient. Otherwise, the one from the nearest context will be used.

0 commit comments

Comments
 (0)