@tanstack/react-query
Advanced tools
Comparing version 5.36.0 to 5.36.1
@@ -1,2 +0,2 @@ | ||
import { MutationFilters, QueryClient, MutationState, Mutation, DefaultError } from '@tanstack/query-core'; | ||
import { MutationFilters, QueryClient, MutationState, Mutation } from '@tanstack/query-core'; | ||
@@ -6,3 +6,3 @@ declare function useIsMutating(filters?: MutationFilters, queryClient?: QueryClient): number; | ||
filters?: MutationFilters; | ||
select?: (mutation: Mutation<unknown, DefaultError, unknown, unknown>) => TResult; | ||
select?: (mutation: Mutation) => TResult; | ||
}; | ||
@@ -9,0 +9,0 @@ declare function useMutationState<TResult = MutationState>(options?: MutationStateOptions<TResult>, queryClient?: QueryClient): Array<TResult>; |
@@ -16,5 +16,3 @@ "use client"; | ||
return mutationCache.findAll(options.filters).map( | ||
(mutation) => options.select ? options.select( | ||
mutation | ||
) : mutation.state | ||
(mutation) => options.select ? options.select(mutation) : mutation.state | ||
); | ||
@@ -21,0 +19,0 @@ } |
@@ -1,2 +0,2 @@ | ||
import { MutationFilters, QueryClient, MutationState, Mutation, DefaultError } from '@tanstack/query-core'; | ||
import { MutationFilters, QueryClient, MutationState, Mutation } from '@tanstack/query-core'; | ||
@@ -6,3 +6,3 @@ declare function useIsMutating(filters?: MutationFilters, queryClient?: QueryClient): number; | ||
filters?: MutationFilters; | ||
select?: (mutation: Mutation<unknown, DefaultError, unknown, unknown>) => TResult; | ||
select?: (mutation: Mutation) => TResult; | ||
}; | ||
@@ -9,0 +9,0 @@ declare function useMutationState<TResult = MutationState>(options?: MutationStateOptions<TResult>, queryClient?: QueryClient): Array<TResult>; |
@@ -16,5 +16,3 @@ "use client"; | ||
return mutationCache.findAll(options.filters).map( | ||
(mutation) => options.select ? options.select( | ||
mutation | ||
) : mutation.state | ||
(mutation) => options.select ? options.select(mutation) : mutation.state | ||
); | ||
@@ -21,0 +19,0 @@ } |
{ | ||
"name": "@tanstack/react-query", | ||
"version": "5.36.0", | ||
"version": "5.36.1", | ||
"description": "Hooks for managing, caching and syncing asynchronous and remote data in React", | ||
@@ -44,3 +44,3 @@ "author": "tannerlinsley", | ||
"dependencies": { | ||
"@tanstack/query-core": "5.36.0" | ||
"@tanstack/query-core": "5.36.1" | ||
}, | ||
@@ -47,0 +47,0 @@ "devDependencies": { |
@@ -7,3 +7,2 @@ 'use client' | ||
import type { | ||
DefaultError, | ||
Mutation, | ||
@@ -29,5 +28,3 @@ MutationCache, | ||
filters?: MutationFilters | ||
select?: ( | ||
mutation: Mutation<unknown, DefaultError, unknown, unknown>, | ||
) => TResult | ||
select?: (mutation: Mutation) => TResult | ||
} | ||
@@ -43,7 +40,3 @@ | ||
(mutation): TResult => | ||
(options.select | ||
? options.select( | ||
mutation as Mutation<unknown, DefaultError, unknown, unknown>, | ||
) | ||
: mutation.state) as TResult, | ||
(options.select ? options.select(mutation) : mutation.state) as TResult, | ||
) | ||
@@ -50,0 +43,0 @@ } |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1066393
21164
+ Added@tanstack/query-core@5.36.1(transitive)
- Removed@tanstack/query-core@5.36.0(transitive)
Updated@tanstack/query-core@5.36.1