Hi Devs, I have two buttons in different function components, each is updating a different state Object via the same handle function passed to them as props from one single parent component. However, when I click one, both state objects gets updated because obviously they are in the same handle function. But I do not want to create a separate function for each button. How do I update just one or the right state Object when one of the buttons is clicked instead of updating both state objects?
This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.