Improving Performance with React-Hook-Form v5 Watch Method in Accordion Table Inputs #12154
Unanswered
khalilbenachir
asked this question in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am working on a React project where I have an array of accordions, and each accordion contains a table of inputs (You, Your Wife, Total). To calculate the total, I am using the watch method from react-hook-form. However, I am experiencing performance degradation in the components.
I cannot use getValues because it does not re-render the component when the values change.
Here are some details:
Library: react-hook-form Version: 5 Has anyone faced similar issues or can suggest an optimized way to handle this scenario?
Thank you in advance for your help!
Beta Was this translation helpful? Give feedback.
All reactions