paper-button 1.0 and appendChild

186 views
Skip to first unread message

Dave Dixon

unread,
Jun 3, 2015, 9:42:57 AM6/3/15
to polym...@googlegroups.com
Hi. When <paper-button> is created via HTML, the content gets moved inside an internal <paper-material> node. But if I instead dynamically populate the content with appendChild(), the content is not moved inside <paper-material>, and the paper-button renders incorrectly. Is this expected?

Dave

Dave Dixon

unread,
Jun 3, 2015, 11:37:57 AM6/3/15
to polym...@googlegroups.com

Justin Fagnani

unread,
Jun 3, 2015, 11:57:20 AM6/3/15
to Dave Dixon, polymer-dev

You need to use Polymer.dom(host).appendChild(child)

This is part of the Shady DOM implementation. I can't find the docs on on our site though...

Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/5757cd10-3ea4-4f12-ab1e-44add5eba2c2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Eric Eslinger

unread,
Jun 3, 2015, 12:03:16 PM6/3/15
to Justin Fagnani, Dave Dixon, polymer-dev

Dave Dixon

unread,
Jun 3, 2015, 12:29:32 PM6/3/15
to polym...@googlegroups.com, dave.d...@gmail.com
That did it - thanks.
Reply all
Reply to author
Forward
0 new messages