Use passive listeners to improve scrolling performance #1605

This commit is contained in:
nymkappa 2022-05-17 11:39:13 +02:00
parent 1ce69061c0
commit 887b222acf

View File

@ -39,7 +39,7 @@ export class ApiDocsComponent implements OnInit {
}
window.addEventListener('scroll', function() {
that.desktopDocsNavPosition = ( window.pageYOffset > 182 ) ? "fixed" : "relative";
});
}, { passive: true} );
}, 1 );
}