jquery count up to number

by T1MOXA

HTML

<span class="count">10 Часов, 20 минут</span>
  <span class="count">23</span>
  <span class="count">40</span>

JavaScript

function increaseJQ(){
  $('.count').each(function () {
      $(this).prop('Counter',0).animate({
          Counter: $(this).text()
      }, {
          duration: 1000,
          easing: 'linear',
          step: function (now) {
              $(this).text(Math.ceil(now));
          }
      });
  }); 
};

/*Pace.on('done', function() {
  increaseJQ()
});*/
increaseJQ();

var DoincreaseNos=false

$(window).scroll(function () {
    if($('.one').hasClass('active')){
        if(DoincreaseNos==true){
            DoincreaseNos=false;
            increaseJQ()  
            console.log('hi')
     			}
  } else {
    DoincreaseNos=true;
  }
});