Debounce any redux action-creator.
const dampen = require('dampen')
const update = dampen(250, payload =>
({ type: 'UPDATE', payload })
)
// elsewhere...
dispatch(update('one'))
dispatch(update('two'))
dispatch(update('three'))
// only { type: 'UPDATE', payload: 'three' }
// will be dispatched after 250ms
Requires redux-thunk
or native support for thunks to function properly.