Skip to content

valid-template-root root requires exactly one element;vue3使用多根节点 #1976

@Perfumere

Description

@Perfumere

Info

  • Platform: Win & Mac
  • Vetur version:0.24.0
  • VS Code version:April 2020 (version 1.45.1)

Problem

When I use vue-next,I got an error
What should I do to not see it
在模板使用多根节点,报错如下

// app.vue
<template>
    <demo-layout />
    <demo-container />
    <demo-menu />
    <demo-button />
</template>

[vue/valid-template-root]
The template root requires exactly one element.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions