Javascript VS jQuery Find Scroll Direction (v5)

Revision 5 of this benchmark created by Joshua Wise on


Preparation HTML

<script src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>

Test runner

Ready to run.

Testing in
TestOps/sec
Javascript Solution
document.body.scrollTop;
ready
jQuery Solution
$(window).scrollTop();
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.