JSFiddle - React, Tailwind, and code Playground

by luka kupunia

HTML

<script src="https://cdnjs.cloudflare.com/ajax/libs/countup.js/1.8.5/countUp.min.js"></script>
<div id="demo">1000</div>

JavaScript

const easingFn = function (t, b, c, d) {
  var ts = (t /= d) * t;
  var tc = ts * t;
  return b + c * (tc + -3 * ts + 3 * t);
  }
const options = {
  easingFn,
};
let demo = new CountUp('demo', 0 , 1150758, 0 , options);
if (!demo.error) {
  demo.start();
} else {
  console.error(demo.error);
}