Debouncing ensures that a handler is not executed too often for an event that may be happening several times per second.
Questions tagged [debouncing]
698 questions
0
votes
2 answers
Debounce Wordpress action hook (or any other PHP function)
I have a Wordpress plugin which sends post data after a post/postmeta change occurs.
The problem is that there can be very many postmeta changes on a busy Wordpress site, so I'd like to debounce/throttle/aggregate the meta updates to a single POST…

steakoverflow
- 1,206
- 2
- 15
- 24
0
votes
1 answer
Trigger debounce function two times independently
I have declared 'service':
// myService.js
export default {
someService: _.debounce(
function someService(rule, value, callback) {
myApi.get(
`check-input/${value}`,
)
.then((response) => {
if…

Paweł Jaworowski
- 253
- 2
- 8
0
votes
2 answers
Accumulate ids to make a single ajax request
I have multiple places where I need to make ajax requests to fetch the items corresponding to some ids. However, I only want to make a single request by accumulating these ids and debouncing the actual method that makes the ajax request...So far…

Amr Noman
- 2,597
- 13
- 24
0
votes
2 answers
Debounced from Polymer properties observer appears to fail
If I call a Polymer debouncer from a button click it works perfectly. I click 5 times in less than 2 seconds, prints only one timestamp:
myProofOfConcept(){
this.__debouncer = Polymer.Debouncer.debounce(
.__debouncer,
…

petecarapetyan
- 61
- 7
0
votes
0 answers
Debounce function does not reduce stutter with heavy computations
I have some sliders, that when changed runs a fairly heavy computation function.
This results in some heavy stuttering when dragging the slider, and a generally bad experience overall.
So my idea was to use debouncing, so that if the last…

Glinkis
- 83
- 6
0
votes
0 answers
Convert a jquery onwindow resizing height adjustment to a table to Angular 4
I wanted a table to take up as much of the lower part of the screen as possible and it have a horizontal and vertical scroll bar always in view therefore I have a little script run upon browser resize (need it to run also upon page init) that…

Matt
- 1
- 3
0
votes
1 answer
How to throttle requestFrameAnimation on a range input?
I have a simple range input and I would like to return the value, every few seconds.
I created two callback functions func and step. I would like to create another callback function that gets called every x seconds from inside rangeListener
Any…

Patrioticcow
- 26,422
- 75
- 217
- 337
0
votes
2 answers
How to pass an event through the Subject update in Javascript?
We have been facing a problem of passing the event from the html to one of the Javascript methods that requires it.
export class SearchComponent implements OnInit {
txtQueryChanged: Subject = new Subject();
constructor(private…

koustubh
- 96
- 1
- 7
0
votes
1 answer
Debounce doesn't respect the timeout
I am trying to setup a debounce function which will handle an HTTP request function. The code is very similar to the following one, basically, I only changed the functions naming.
Firstly, I am using this debounce function.
function debounced(fn,…

urb
- 924
- 1
- 13
- 28
0
votes
1 answer
VueJS how to use _.debounce on data changes
I'm building a little vue.js-application where I do some post requests. I use the watch-method to whach for api changes which then updates the component if the post request is successfull. Since the watcher constantly checks the API I want to add…

ST80
- 3,565
- 16
- 64
- 124
0
votes
1 answer
How to Debounce with Observer Polymer
I am trying to run getResponse once when a web components finishes loading. However, when I try to run this, the debounce function just acts as an async delay and runs 4 times after 5000 ms.
static get properties() {
return {
procedure: {
…

Matthew
- 1,461
- 3
- 23
- 49
0
votes
1 answer
passing bound argument through debounce to wrapped function
I have a function that already binds an argument to a listener callback. It was working great but now I need to debounce (lodash) that
I can't seem to get the binding for debounce right so that argument pin_num gets passed along to the .bind of…

DKebler
- 1,216
- 1
- 15
- 27
0
votes
2 answers
How to explicitly override AngularJS model debouncing?
On one of the pages in our AngularJS 1.* application, I am looking at a text input1 whose debounce is set to a value greater than zero. It is configured roughly like this:

O. R. Mapper
- 20,083
- 9
- 69
- 114
0
votes
1 answer
Why debounce doesnt invoke my function?
Im working on something with React and mobx.
I created an ImageCarousel Component where I show the image that was clicked.
I have a previous and a next buttons(which are themselves a Component), to move between images.
I tried to wrap those actions…

ueeieiie
- 1,412
- 2
- 15
- 42
0
votes
1 answer
Micropython: How to debounce the Pyboard USR switch?
I currently have this MicroPython code running on a Pyboard v1.1:
import pyb
def toggle_led():
pyb.LED(3).toggle()
sw = pyb.Switch()
sw.callback(toggle_led)
However, this setup is susceptible to contact bounce.
I tried adding up to…

Serge Stroobandt
- 28,495
- 9
- 107
- 102