I am looking to disable a button (material ui) when it is clicked for the second time by setting disabled={true}
. Unfortunately, I have not been able to find any examples related to this specific scenario on StackOverflow.
<Button
onClick={this.startDraw.bind(this)}
disabled={}
startIcon={<Brush />}
>
Initially, the button is clickable and triggers an action when clicked. However, my goal is to make sure that when the same button is clicked again for the second time, it becomes disabled and cannot be clicked anymore.