Reduce throttle delay
This commit is contained in:
parent
d00c70f804
commit
2303a02839
@ -146,8 +146,8 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.debouncedResize = throttle(this.handleResize, 500);
|
this.debouncedResize = throttle(this.handleResize, 100);
|
||||||
this.debouncedScroll = throttle(this.handleScroll, 150);
|
this.debouncedScroll = throttle(this.handleScroll, 100);
|
||||||
|
|
||||||
window.addEventListener("resize", this.debouncedResize, {passive: true});
|
window.addEventListener("resize", this.debouncedResize, {passive: true});
|
||||||
this.$refs.chat.addEventListener("scroll", this.debouncedScroll, {passive: true});
|
this.$refs.chat.addEventListener("scroll", this.debouncedScroll, {passive: true});
|
||||||
|
Loading…
Reference in New Issue
Block a user