Note.. I use Mootools so my code may be slightly different than what you need.
Your template looks like this:
- <% Array.each(this.attr("pets"), function(pet, index) { %>
- <span <%= (el) -> can.data(el, "pet", index) %>><%= pet %></span>
- <% }); %>
If span is an input, you also have to do some trickery in the controller to bind value changes. This is why I store the index of the pet in the elements data.