since i'm new to jquery i wanted to ask you how i can Start animation on progress bar when its visible on screen with jquery .
this is my query code is not complete I don’t know how i complete:
$(".progress-bar").each(function(){
var percentage = parseInt($(this).html());
if(percentage > 0){
$(this).animate({'width':''+percentage+'%'}, 800);
}else{
$(this).css({'color':'black', 'background':'none'}, 800);
}
});
and this is Html
<div class="skill">
<div class="progress">
<div class="progress-bar">100%</div>
</div>
<h5>German</h5>
</div>
Thanks for your help in advance