Implement debounce option

Fixes #23