vue-agile icon indicating copy to clipboard operation
vue-agile copied to clipboard

Lighthouse optimization : Does not use passive listeners to improve scrolling performance

Open juliender opened this issue 3 years ago • 0 comments

Describe the bug In lighthouse, there is a warning concerning event listeners :

Does not use passive listeners to improve scrolling performance Consider marking your touch and wheel event listeners as passive to improve your page's scroll performance.

Code Lines 202-207 this.$refs.track.addEventListener('touchstart', this.handleMouseDown)

The warning disappears by adding {passive : true}

Ie for line 202, the code becomes this.$refs.track.addEventListener('touchstart', this.handleMouseDown, {passive : true})

Regards

juliender avatar Jan 06 '22 09:01 juliender