From 82d2c3054dac80c44fa2c46ce9c7fb4e39b4def5 Mon Sep 17 00:00:00 2001 From: Alexander Alexeev Date: Mon, 21 Aug 2023 02:19:11 +0400 Subject: [PATCH] Reset form after submission --- src/App.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/App.tsx b/src/App.tsx index 4f3dad6..e8fabad 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -44,6 +44,7 @@ export const App = () => { const { register, + reset, formState: { errors, }, @@ -53,6 +54,7 @@ export const App = () => { const onSubmit: SubmitHandler = data => { alert(JSON.stringify(data)) + reset() } //Проверка капчи