Something went wrong. Try again.
☢ Make Your React App Truly Reactive!
Something went wrong. Try again.
242 B · 12 lines
JavaScript
at master
123456789101112// schedule the callback (cb) to be run asynchronously only onceconst schedule = (cb) => { if (!cb.scheduled) { cb.scheduled = true setTimeout(() => { cb() cb.scheduled = false }, 0) }}
module.exports = schedule