In Polymer, alone, without combining with Meteor, you can pass an object to a polymer web component by simply passing it to an attribute. I've been successful at doing this. Here we're passing "state" from the iteration directly into the custom polymer web component called state-card.
<template repeat="{{state in states}}">
<state-card class="state-card" stateObj={{state}}></state-card>
</template>
However, in my project, I am combining Polymer and Meteor.
Polymer's templates and Meteor's blaze templates can't be mixed ... so, this is blaze with just a custom Polymer web component.
I could not pass the "state" object in Meteor with blaze #each loop in a meteor template.
As a work-a-round I found I could only pass the individual properties as text strings
like so ...
<template name="inbox">
<div class="content" flex>
{{#each states}}
<state-card class="state-card" name={{name}} status={{status}} displayType={{displaytype}}></state-card>
{{/each}}
</div>
</template>
to accomplish the above, here is a snippet from the custom Polymer web component with an attribute like so ...
<polymer-element name="state-card" attributes="name status displayType" on-click="cardClicked">
<template>
...
</template>
</polymer-element>
What I "really" want to do is just pass in the object directly to the polymer web component like so ... but, sadly this just won't work
<template name="inbox">
<div class="content" flex>
{{#each states}}
<state-card class="state-card" stateObj={{this}}></state-card>
{{/each}}
</div>
</template>
Ideally, I should be able to accept the object with an attribute like so ...
<polymer-element name="state-card" attributes="stateObj" on-click="cardClicked">
<template>
...
</template>
</polymer-element>
This SO question/answer is "very" similar to my issue, but, the answer didn't work because I have the Meteor blaze template complication ...
I "really" don't want to stick with my work-a-round ... even though it works.
I've read elsewhere on SO that in a blaze #each iteration you can access the object literal like so ...
{{#each humans}}
{{this}}
{{/each}}
But, I couldn't make this work. I would be very appreciative of any help and guidance. I understand what I'm trying to do, combine Polymer and Meteor is somewhat problematic, but, I've seen it done and I've made a lot of progress. I'm just stumbling at this point. Thanks!!!