marko krstić

Collections

Archives

Rotate logo on scroll

If you need to rotate logo while you are scrolling the page like on Matthias Altmann's website here is the code he shared with us

(function($) {
	$(document).ready(function(){
		$(window).scroll(function() {
		var deg = $(window).scrollTop()/2;
		$('#header-company-logo').css({ transform: 'rotate(' + deg + 'deg)' });
		});
	});
})(jQuery);

Example: https://www.altmann.de/

Let's Connect

Feel free to reach out for collaborations or just a friendly hello ?
[email protected]
linkedininstagramdribbblefacebook-official