Dark Mode

Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit ec24e0e

Browse files
committed
Finished Debouncing
1 parent d29907f commit ec24e0e

File tree

1 file changed

+1
-6
lines changed
  • JS
    • JS-br.md

1 file changed

+1
-6
lines changed

JS/JS-br.md

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1121,12 +1121,7 @@ _.debounce = function(func, wait, immediate) {
11211121
A implementacao completa da funcao nao e tao dificil.
11221122
11231123
- Para a implementacao de proteger contra clicks acidentais: enquanto eu comecar o time e o time existir, nao importa quantas vezes eu clicar o butao, a funcao de callback nao sera executada. Contudo quando o time termina, e setado para `null`, outro click e permitido.
1124-
-
1125-
1126-
The complete function implementation is not too difficult. Let's summarize here.
1127-
1128-
- For the implementation of protecting against accidental clicks: as long as I start a timer and the timer is there, no matter how you click the button, the callback function won't be executed. Whenever the timer ends and is set to `null`, another click is allowed.
1129-
- For the implementation of a delayed function execution: every call to the debouncing function will trigger an evaluation of time interval between the current call and the last one. If the interval is less than the required, another timer will be created, and the delay is set to the set interval minus the previous elapsed time. When the time's up, the corresponding callback function is executed.
1124+
- Para a implementacao da executacao da funcao de atraso: toda chamada para a funcao debouncing vai disparar um tempo de intervalo equivalente entre a chamada tual e a ultima chamada. Se o intervalo e menor que o requerido, outro time sera cirado, e o atraso e atribuido ao set interval menos o tempo anterior. Quando o tempo passa, a funcao de callback e executada.
11301125
11311126
# Throttle
11321127

0 commit comments

Comments
(0)