javascript - Smooth Scroll JQuery doesn't work smoothly in Chrome? -


i using jquery script vertical smooth scrolling effect. works in internet explorer , firefox it's not smooth @ in google chrome's latest version??? how come? should change in script or there smooth scroll script works nice , smooth across browsers?

in google chrome, smooth scroll effect jiggles , stops brief moment looks kinda ugly.

here javascript/jquery code:

(function() {     $('header ul a').bind('click',function(event){         var $anchor = $(this);          $('html, body').animate({             scrolltop: $($anchor.attr('href')).offset().top + "px"         }, 1500);         /*         if don't want use easing effects:         $('html, body').stop().animate({             scrolltop: $($anchor.attr('href')).offset().top         }, 1000);         */         event.preventdefault();     }); }); 

my html has 5 <section>'s , each section has it's own id (home, about, services, gallery , contact) there nothing spectacular here. help!


Comments

Popular posts from this blog

How to mention the localhost in android -

php - Calling a template part from a post -