Skip to content

Instantly share code, notes, and snippets.

@IgorGavrilenko
Last active September 23, 2016 21:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save IgorGavrilenko/1d91b8b5a0e462e38c43 to your computer and use it in GitHub Desktop.
Save IgorGavrilenko/1d91b8b5a0e462e38c43 to your computer and use it in GitHub Desktop.
scroll Top
$("a[href='#top']").click(function() {
$("html, body").animate({ scrollTop: 0 }, "slow");
return false;
});
$('.point-1').click(function(e) {
e.preventDefault();
$('html, body').animate({
scrollTop: $('.item').offset().top
}, 500);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment