Excessive re-rendering from useForm hook #1193
Replies: 7 comments 11 replies
-
I'll see what we can do, but that is not a priority. |
Beta Was this translation helpful? Give feedback.
-
It re-render the whole form when interaction with form field |
Beta Was this translation helpful? Give feedback.
-
Im using component inside a form, and its re-rendering everytime I slide the mouse over the color grid.. I think its better to useRef in this case 😕 , right? |
Beta Was this translation helpful? Give feedback.
-
Is there any solution to this problem? |
Beta Was this translation helpful? Give feedback.
-
We had to move to https://github.com/react-hook-form/react-hook-form |
Beta Was this translation helpful? Give feedback.
-
We are seeing this still an issue in Mantine 7.5.1. @rtivital - any guidance on how to limit the re-renders while using the useForm hook? |
Beta Was this translation helpful? Give feedback.
-
All performance issues have been resolved with uncontrolled form mode – https://mantine.dev/form/uncontrolled/ |
Beta Was this translation helpful? Give feedback.
-
Hello, I'm noticing that updating any value within the form will trigger a re-render of the parent component where the useForm hook is located. Even after destructuring the returned object from useForm, I'm noticing that functions such as getInputProps or addListItem are also being changed.
Are there plans to optimize performance of this hook? Such as wrapping functions in useCallback, or using refs?
Thank you Vitaly for the excellent library.
Beta Was this translation helpful? Give feedback.
All reactions