Is it necessary to clearTimeout inside a recursively invoked timer?

后端 未结 1 995
闹比i
闹比i 2021-01-24 21:13

Is it necessary to call clearTimeout() inside a recursively invoked function in Coffeescript?

My concern is whether not calling clearTimeout()

相关标签:
1条回答
  • 2021-01-24 21:47

    No, setTimeout schedules a one-off event. Once the event has occurred, clearTimeout with that handle is a no-op.

    0 讨论(0)
提交回复
热议问题