How can I access the host of a custom element
问题 I have a custom element which itself hosts a custom element. <polymer-element name="flex-nonvisual"> <template> <polymer-flex-layout></polymer-flex-layout> </template> </polymer-element> Now in attached() (or some other callback) of PolymerFlexLayout I want to set the class attribute of the flex-nonvisual element. In Javascript the code looks like this.parentNode.host.classList.add('someclass'); In Dart in attached() (after the call to super.attached() ) this.parent is null and I couldn't