score:0

you can check that the event's detail property is 1, meaning it's not the second click of a double click.

if (e.detail !== 1) { return }

or use something like lodash's throttle

handle_click = _.throttle(func, 500)

which will ensure the function can be called a most one time per 500ms

score:0

since, you are already recording number of clicks. how about you disable the button when the modal is opened and enable it once the modal is closed?

return <button
  type='button'
  classname={
    this.state.ismodalactive ? 'disable' : ''
  }
  onclick={ this.handleclick }
>

make sure you update the state ismodalactive on each interaction with the button.


Related Query

More Query from same tag