Hi. I found this code, but it only allows me to have one number count up. It won’t let me redeclare. Any idea or help is appreciated. Also, I need the number to show as a dollar amount. See the screenshot below.
let startNum = 0 ;
let endNum = 23978 ;
const duration = 10 ; // 1000 milliseconds
$w . onReady ( function (){ setInterval (() => { countUp ();}, duration );});
function countUp (){ if ( startNum <= endNum ){ $w ( ‘#text112’ ). text = startNum . toLocaleString (). toString (); startNum ++ ;}}