From deec587c5f5e7b5bae0cc1aa5f0d6b16e907cfcf Mon Sep 17 00:00:00 2001 From: Dongmin Date: Fri, 30 Aug 2024 16:25:36 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20Optimistic=20Update=20=EC=BD=94=EB=93=9C?= =?UTF-8?q?=20=EC=98=A4=EB=A5=98=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `onMutate`의 argument가 생략되어 있어 추가했습니다. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e2a32d0..0b4cb62 100644 --- a/README.md +++ b/README.md @@ -1230,7 +1230,7 @@ const useAddSuperHeroData = () => { const queryClient = useQueryClient(); return useMutation({ mutateFn: addSuperHero, - onMutate: async () => { + onMutate: async (newHero: any) => { await queryClient.cancelQueries(["super-heroes"]); // 이전 값