Sometimes you may want to skip the Shadow DOM completely with Polymer.
相关问题
- How can I dynamically add items into paper-dropdow
- 2 way data-binding between a polymer component and
- Shadow DOM CSS Styling from outside is not working
- How to get Polymer 2.0 ES5 elements working with v
- Extending native HTML element in Angular 6
相关文章
- Access shadow DOM properties (polymer) with javasc
- Vanilla Web Component custom event attributes and
- document.querySelector() returns null
- Updating Polymer component via Websocket?
- polymer duplicate element content
- Where is it best to handle the business logic in m
- How do you bind Polymer elements to a Model in ASP
- Polymer 2.0: Notify and reflect to attribute
You can force your Polymer Element's template into the Light DOM by overriding
parseDeclaration
on yourPolymer()
JS/Coffeescript declaration.Coffeescript Example:
Of course, you have to be careful because if you have anything that belongs in the Shadow DOM (like a stylesheet) in your template, it will now be in the Light DOM.
Edit: If there's a better way to do this, please let me know.