debounce icon indicating copy to clipboard operation
debounce copied to clipboard

callback not be invoked if interval is shorter than `after` param

Open zitudu opened this issue 4 years ago • 0 comments

Example:

d := New(1 * time.Second)

for i := 0; i < 10; i++ {
  d(func () {
    println("called")
  })
  time.Sleep(900 * time.Millisecond)
}

Expected:

"called" should be printed 8~9 times.

zitudu avatar Dec 11 '21 02:12 zitudu