[Vue warn]: Avoid using non-primitive value as key, use string/number value instead.

[Vue warn]: Avoid using non-primitive value as key, use string/number value instead.

 

<div v-for="item in workData" :key="item"><div>

item是数组或者对象

改为:

<div v-for="(item,index) in workData" :key="index"></div>

 

上一篇:Java - 你的 Java 代码有这些坏味道吗?


下一篇:eslint-----------standard 代码规范