Closed kyoukhana closed 9 years ago
I figured it out
jQuery('[data-theme]').each(function(){
var v = jQuery(this).data('start');
var o = new Odometer({
el: this,
value:0,
theme: jQuery(this).data('theme')
});
o.render();
setInterval(function(){
o.update(v);
}, 3000);
});
Glad you figured it out!
I want to have multiple odometers on one page. How do I call the library using jQuery to do this. Also I have a data-set attribute so when calling the library from jQuery it will pull the value from there and display the Odometers.