Skip to content

Commit 8853a35

Browse files
committed
Restore TS types for query status field
1 parent 59f8fa5 commit 8853a35

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

packages/toolkit/src/query/react/buildHooks.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,14 @@ type UseQueryStateDefaultResult<D extends QueryDefinition<any, any, any, any>> =
452452
Pick<UseQueryStateBaseResult<D>, 'error'>
453453
>)
454454
>
455-
>
455+
> & {
456+
/**
457+
* @deprecated Included for completeness, but discouraged.
458+
* Please use the `isLoading`, `isFetching`, `isSuccess`, `isError`
459+
* and `isUninitialized` flags instead
460+
*/
461+
status: QueryStatus
462+
}
456463

457464
export type MutationStateSelector<
458465
R extends Record<string, any>,

0 commit comments

Comments
 (0)