nico
Published in : 2022-04-16
Hello, all i noticed that my component was rendered three times when I update an input in my form.
It is not good and feel like a performance problem.
So my question is : when a component is rendered, how can we know what state was updated when the function component is rendered?
That way I will try to optimize the code so the function component is rendered only once when I update the input of the form.
Thanks for your help
Join our community and get the chance to solve your code issues & share your opinion with us
Sign up Now
Mohamed Atef Date : 2022-04-16
Best answers
51
Best answers
51
I prefer to use Formik for Reactjs forms it's away better than using states and updating states on input change
nico Date : 2022-04-16
Best answers
4
Best answers
4
Ironic, I use Formik in my case !
I see the call %c xxx called" 3 times each time I update one input…
so it seems overkill
nico Date : 2022-04-16
Best answers
4
Best answers
4
it seems in devtool there is one option:
but do you know how to use it?