Home

Issue: 2141

v-else hydrate inconsistency

[issue link]

Problem

Using v-if and v-else directives to conditionally output a single root element for a component template fails if the v-else directive is attached to an HTML element, but works as expected when attached to a component.

Tested in latest Chrome, Firefox, and Safari on macOS 10.12 with Nuxt v1.0.0-rc11.

Minimal, reproducible example

https://github.com/alexcruice/nuxt-v-else

Screenshots

Render
screen_shot_2017-11-18_at_9_55_21_am

Source
screen_shot_2017-11-18_at_9_55_48_am

Console output
screen shot 2017-11-18 at 9 57 07 am

This question is available on Nuxt.js community (#c1897)