vue-lazy-hydration icon indicating copy to clipboard operation
vue-lazy-hydration copied to clipboard

fix: do not hydrate single root elements

Open simllll opened this issue 4 years ago • 1 comments

I have a component with several v-if v-else-ifs and some other logic in there, but at the end it only exposes one single root element. due to the check of childElementCount this was immediately hydrated, even though it shouldn't. Checking for nodeType seems more reliable and is fully supported in all browsers.

simllll avatar May 01 '20 21:05 simllll

if it achieves the same, it should be fine. I can't really say anmore, but I waas playing around with nodeType too, but I didn't get it to work as expected

@weotch can you run my tests against your PR? do they work?

simllll avatar Aug 11 '20 18:08 simllll