I don’t understand what is the difference between assigning my handleButton
method to the props
with and without the arrow function. In React Developer Tools
I see only this statement func: f func() {}
and func2: f () {}
, can you explain me the difference?
Code:
<MathButton
operator="-"
number={10}
func={() => {
this.handleButton;
}}
func2={this.handleButton}
></MathButton>