Let's say you have a Parent component which defines a method:
    class Parent extends Component {
     handleX() {
       this.setState({ x: true });
     }
   }
If I pass this function as props to Child and call it on for example a button click, which state will be updated - Child or Parent? What is the correct way to use this?
 
    