javascript - Trigger script on scroll -
jquery({somevalue: 0}).animate({somevalue: 38}, { duration: 1500, easing:'swing', step: function() { $('#grow1').text(math.ceil(this.somevalue)); } });
how can make sure animation doesn't start until user scrolls down particular div?
you can use http://scrollmagic.io. allows define triggers in page , execute callbacks (in case animation) when triggers reached user. take @ example: http://scrollmagic.io/examples/basic/custom_actions.html
hope you
Comments
Post a Comment