JQuery Check Scroll -Richtung

let scrollDirection = '';
let scrollTopPosition = 0;
$(window).on('scroll', function() {
	if(scrollTopPosition > $(window).scrollTop()) {
		scrollDirection = 'to-top';
	} else {
		scrollDirection = 'to-bottom';
	}
	
	scrollTopPosition = $(window).scrollTop();
});

console.log(scrollDirection);
Kasmin Nicko