Reactjs – Prevent in between re-renders when using two State hooks connected by a useEffect hook
I have two State hooks s1, s2 and a useEffect hook updating s2 if the s1 is updated. How to prevent re-renders after s1 update and before s2 update? The program depends on the coherence between s1 and s2 and…