Table: Add eventListener option passive

pull/8971/head
Akiho Nagao 2017-12-16 16:24:11 +09:00 committed by 杨奕
parent 0d952b7917
commit 8d15a86df2
1 changed files with 1 additions and 1 deletions

View File

@ -96,7 +96,7 @@ const isFirefox = typeof navigator !== 'undefined' && navigator.userAgent.toLowe
export const mousewheel = function(element, callback) {
if (element && element.addEventListener) {
element.addEventListener(isFirefox ? 'DOMMouseScroll' : 'mousewheel', callback);
element.addEventListener(isFirefox ? 'DOMMouseScroll' : 'mousewheel', callback, { passive: true });
}
};