I don't know whether I follow you, the following may not help but let's try.
The first argument of link_to is an arbitrary HTML fragment. You can
put there whatever you want.
The helper image_tag just returns a string containing HTML: "<img ...
/>", and that is what link_to receives in the first example. Just a
vanilla Ruby string. You can build on that one to pass whatever you
want to link_to.