File tree Expand file tree Collapse file tree 5 files changed +20
-36
lines changed Expand file tree Collapse file tree 5 files changed +20
-36
lines changed Original file line number Diff line number Diff line change @@ -137,7 +137,7 @@ export function useBaseQuery<
137137
138138 run ( )
139139
140- stopWatch = watch ( defaultedOptions , run , { deep : true } )
140+ stopWatch = watch ( defaultedOptions , run )
141141 } ,
142142 )
143143 }
Original file line number Diff line number Diff line change @@ -21,13 +21,9 @@ export function useIsFetching(
2121 isFetching . value = client . isFetching ( filters )
2222 } )
2323
24- watch (
25- filters ,
26- ( ) => {
27- isFetching . value = client . isFetching ( filters )
28- } ,
29- { deep : true } ,
30- )
24+ watch ( filters , ( ) => {
25+ isFetching . value = client . isFetching ( filters )
26+ } )
3127
3228 onScopeDispose ( ( ) => {
3329 unsubscribe ( )
Original file line number Diff line number Diff line change @@ -84,13 +84,9 @@ export function useMutation<
8484 } )
8585 }
8686
87- watch (
88- options ,
89- ( ) => {
90- observer . setOptions ( options . value )
91- } ,
92- { deep : true } ,
93- )
87+ watch ( options , ( ) => {
88+ observer . setOptions ( options . value )
89+ } )
9490
9591 onScopeDispose ( ( ) => {
9692 unsubscribe ( )
Original file line number Diff line number Diff line change @@ -65,13 +65,9 @@ export function useMutationState<TResult = MutationState>(
6565 state . value = result
6666 } )
6767
68- watch (
69- filters ,
70- ( ) => {
71- state . value = getResult ( mutationCache , options )
72- } ,
73- { deep : true } ,
74- )
68+ watch ( filters , ( ) => {
69+ state . value = getResult ( mutationCache , options )
70+ } )
7571
7672 onScopeDispose ( ( ) => {
7773 unsubscribe ( )
Original file line number Diff line number Diff line change @@ -207,20 +207,16 @@ export function useQueries<
207207 { immediate : true } ,
208208 )
209209
210- watch (
211- [ defaultedQueries ] ,
212- ( ) => {
213- observer . setQueries (
214- defaultedQueries . value ,
215- options as QueriesObserverOptions < TCombinedResult > ,
216- )
217- const [ , getCombinedResultPersisted ] = observer . getOptimisticResult (
218- defaultedQueries . value ,
219- )
220- state . value = getCombinedResultPersisted ( )
221- } ,
222- { deep : true } ,
223- )
210+ watch ( defaultedQueries , ( ) => {
211+ observer . setQueries (
212+ defaultedQueries . value ,
213+ options as QueriesObserverOptions < TCombinedResult > ,
214+ )
215+ const [ , getCombinedResultPersisted ] = observer . getOptimisticResult (
216+ defaultedQueries . value ,
217+ )
218+ state . value = getCombinedResultPersisted ( )
219+ } )
224220
225221 onScopeDispose ( ( ) => {
226222 unsubscribe ( )
You can’t perform that action at this time.
0 commit comments