Merge pull request #1658 from mempool/nymkappa/bugfix/passive-listener

Use passive listeners to improve scrolling performance
This commit is contained in:
wiz 2022-05-18 19:51:04 +09:00 committed by GitHub
commit 383addc470
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

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 );
}