Templates 如何从聚合物模板中访问自定义元素的主体?

Templates 如何从聚合物模板中访问自定义元素的主体?,templates,interpolation,polymer,Templates,Interpolation,Polymer,我有一个定制的聚合物元件。在其元素中,如何访问元素的主体?也就是说,我如何安排: <foo> <em>Clem</em> </foo> 克莱姆 转化为 Hello, <em>Clem</em> 你好,克莱姆 通过一个大概看起来像 <polymer-element name="foo"> <template> Hello, ??? </template> <

我有一个定制的聚合物元件
。在其
元素中,如何访问
元素的主体?也就是说,我如何安排:

<foo>
  <em>Clem</em>
</foo>

克莱姆
转化为

Hello, <em>Clem</em>
你好,克莱姆 通过一个大概看起来像

<polymer-element name="foo">
  <template>
    Hello, ???
  </template>
</polymer-element>

你好
如中所述,您需要使用
标记创建一个插入点


我还应该指出,您的元素名称需要包含一个破折号才能符合规范。因此,它应该是
,而不仅仅是

或多或少的相同问题,而是以更直接的方式表达: