Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(runtime): apply textnodes to shadow DOM instead of light dom
fixes ionic-team#4231 By default the `vdomRender` build flag is `false`. The Stencil parser detects any usage of a `h` function, this flag will be switched. In the component provided by author of the bug there hasn't been any vDOM to be parsed, therefor there was no usage of the function `h`. Now, in `callRender` if we end up not having to render any vDOM we used to just attach the string (can also be a boolean or number) as text to the host element. This however doesn't work when a shadow DOM is registered for the component. In this case the text content is added to the light dom which is not being rendered. To fix this we check if the component has a shadow DOM if attach the text node to that node.
- Loading branch information