Create a gist now

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Плавный сролл до блока
$('a[data-target^="anchor"]').bind('click.smoothscroll', function(){
var target = $(this).attr('href'),
bl_top = $(target).offset().top - 70;
$('body, html').animate({scrollTop: bl_top}, 700);
return false;
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment