Vue:The template root requires exactly one element

<template>之间的所有内容都需要用div包起来

<template>
	<div id="client">
		<div v-for="(item,index) in productList" :key="index">
		{{item.id}}
		</div>
		<v-pagination :total="total" :display="display" :current="current" @pagechange="pagechange"></v-pagination>	
	</div>
</template>

如上图的<div id="client">

发布了153 篇原创文章 · 获赞 30 · 访问量 26万+

猜你喜欢

转载自blog.csdn.net/weixin_41728561/article/details/103685442