首页 > 其他分享 >前端报错踩坑

前端报错踩坑

时间:2022-12-17 09:33:57浏览次数:46  
标签:前端 列表 123 报错 首页 权限

Component template should contain exactly one root element. If you are using v-if on multiple elements, use v-else-if to chain them instead.

<template>  <!-- 面包屑 --> <el-breadcrumb separator="/">   <el-breadcrumb-item :to="{ path: '/home' }">首页</el-breadcrumb-item>   <el-breadcrumb-item>权限管理</el-breadcrumb-item>      <el-breadcrumb-item>权限列表</el-breadcrumb-item> </el-breadcrumb> <!-- //卡片 --> <el-card>123</el-card> </template>

 

解决办法,用div包起来

 

<template> <div>  <!-- 面包屑 --> <el-breadcrumb separator="/">   <el-breadcrumb-item :to="{ path: '/home' }">首页</el-breadcrumb-item>   <el-breadcrumb-item>权限管理</el-breadcrumb-item>      <el-breadcrumb-item>权限列表</el-breadcrumb-item> </el-breadcrumb> <!-- //卡片 --> <el-card>123</el-card> </div>
</template>

标签:前端,列表,123,报错,首页,权限
From: https://www.cnblogs.com/www9527/p/16988615.html

相关文章