Browse Source

Make mouseout event listener passive

Alexandre Dieulot 6 năm trước cách đây
mục cha
commit
9331de4df9
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      instantpage.js

+ 1 - 1
instantpage.js

@@ -27,7 +27,7 @@ function mouseoverListener(event) {
     return
   }
 
-  linkElement.addEventListener('mouseout', mouseoutListener)
+  linkElement.addEventListener('mouseout', mouseoutListener, {passive: true})
 
   urlToPreload = linkElement.href