javascript - Traverse DOM tree of Polymer element -


is possible traverse dom subtree when using polymer element custom-element like

<polymer-element name="custom-element" attributes="something">   <template>   </template>    <script>   // access ul , li actual dom here.   </script> </polymer-element>  <body>   <custom-element something="foo">     <ul>       <li>bar</li>       <li>hello</li>     </ul>   </custom-element> </body> 

i want able parameterize polymer element using markup that's wrapped it.

actually, this.children allows access them.

<polymer-element name="custom-element" attributes="something">   <template>   </template>    <script>   polymer({     created: function() {       console.log(this.children);     }   });   </script> </polymer-element> 

Comments

Popular posts from this blog

java - Oracle EBS .ClassNotFoundException: oracle.apps.fnd.formsClient.FormsLauncher.class ERROR -

c# - how to use buttonedit in devexpress gridcontrol -

nvd3.js - angularjs-nvd3-directives setting color in legend as well as in chart elements -