Skip to content

Commit 67c2c71

Browse files
committed
Add event listeners passive for fotorama lib improves lighthouse metrics
1 parent 8c95f07 commit 67c2c71

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/web/fotorama/fotorama.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1137,7 +1137,7 @@ fotoramaVersion = '4.6.4';
11371137

11381138
function addEvent(el, e, fn, bool) {
11391139
if (!e) return;
1140-
el.addEventListener ? el.addEventListener(e, fn, !!bool) : el.attachEvent('on' + e, fn);
1140+
el.addEventListener ? el.addEventListener(e, fn, {passive: true}) : el.attachEvent('on' + e, fn);
11411141
}
11421142

11431143
/**

0 commit comments

Comments
 (0)