jQuery(document).ready(function($){ $('.nb-progress').each(function(){ var a = $(this).find('.nb-progress-bar'), b = $(a).data('percent'); waypoint = new Waypoint({ element: a, handler: function() { a.css('min-width',b+'%'); }, offset: 'bottom-in-view' }); }); } );