解决 debounce 当 immediate 入参 false 的时候,args无法被赋值,导致取不到入参的问题
解决 debounce 当 immediate 入参 false 的时候,args无法被赋值,导致取不到入参的问题pull/3487/head
parent
1bc2e5c198
commit
e6ab249ce4
|
@ -271,7 +271,8 @@ export function debounce(func, wait, immediate) {
|
|||
}
|
||||
}
|
||||
|
||||
return function(...args) {
|
||||
return function() {
|
||||
args = arguments
|
||||
context = this
|
||||
timestamp = +new Date()
|
||||
const callNow = immediate && !timeout
|
||||
|
|
Loading…
Reference in New Issue