Suggestion: relax invalid-template-root
for v-if
#41
Labels
Milestone
invalid-template-root
for v-if
#41
Tell us about your environment
Conditionally empty template root can be acceptable. For example, in a list item component, if an item is empty/undefined, empty template root represents
skipping render
.The reason behind it is that we can encapsulate null check in the component, so we can pass empty value to the component.
vue-hackernews also employs such strategy.
https://github.com/vuejs/vue-hackernews-2.0/blob/master/src/components/Comment.vue#L2
The text was updated successfully, but these errors were encountered: