I am having trouble figuring out which set of quotation marks are appropriate to get the image below to load. The #icon + i part does work as I put in a sample image to append and the correct div is referenced. But I'm not able to figure out how to get the appropriate image to be loaded within src.
$(document).ready(function(){
  alert('test');
  <% if @iosapps %>
  for (var i =0; i < <%= @iosapps.length %>; i++) {
    $('#icon' + i).append('<img src = "<%= @iosapps['+i+'].app_store_icon %>">');
  }
  <% end %>
});
The error I currently get is: can't convert String into Integer
 
    