Setting state of toggle button causes click handler to trigger
I am setting the state of a toggle button with forceState(state). I also have an action set up which gets triggered when the button is clicked. Currently I am facing the issue that when I force the state of the button, then I am also getting the action as if the button was clicked. This is completely unnecessary, since I already know which state the button is in. So I have to write some extra code which checks if the action was caused by calling forceState(state) or not. Is there a way to change the behavior, so forceState(state) does not trigger the action or is there a different function for setting the state?
