$(document).ready(()=>{ const compatibility = $('.compatibility') const sheets = compatibility.find('.sheet-container') const values = sheets.find('.value') values.each((index,elem)=>{ const el = $(elem) const percent = el.find('.percent') const value = percent.data('percent')+'%' console.log(percent) percent.animate({'width': value},500) }) })