我有下表<table class="table-auto w-full"> <tbody> <tr v-for="items in planItems" :key="items.id"> <td class="border px-4 py-2">{{ items }}</td> </tr> </tbody></table>我正在遍历所有项目,我有以下内容<script>export default { name: "PlanItem", props: { planIcon: { type: String, required: false }, planIconAlt: { type: String, required: false }, planName: String, planPrice: String, items: Array, planOrderLink: String }, data() { return { planItems: this.items }; }};</script>并在传递组件时执行以下操作items="[1GB]",但是,我的输出是这样的我究竟做错了什么?
- 2 回答
- 0 关注
- 92 浏览
添加回答
举报
0/150
提交
取消