()
| 47 | } |
| 48 | |
| 49 | export function useCreateTask() { |
| 50 | const queryClient = useQueryClient(); |
| 51 | |
| 52 | return useMutation({ |
| 53 | mutationFn: apiClient.createTask, |
| 54 | onSuccess: () => { |
| 55 | // Invalidate all task queries |
| 56 | queryClient.invalidateQueries({ queryKey: ['tasks'] }); |
| 57 | queryClient.invalidateQueries({ queryKey: ['parents'] }); |
| 58 | }, |
| 59 | }); |
| 60 | } |
| 61 | |
| 62 | export function useUpdateTask() { |
| 63 | const queryClient = useQueryClient(); |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…