网站更新内容:请访问: https://bigdata.ministep.cn/

antd table提示Warning: Each child in a list should have a unique "key" prop.

参考:

表中的每条记录都应该有一个唯一的“key”属性,或者将“rowKey”设置为唯一的主键。 · 问题 #7623 · ant-design/ant-design

解决

<Table 
  columns={columns} 
  dataSource={this.props.categories} 
  rowKey="name" 
/>

原因:column没有指定key,那就在表中指定下

其他解决办法,见issues的说明

posted @ 2023-07-15 14:07  ministep88  阅读(393)  评论(0编辑  收藏  举报
网站更新内容:请访问:https://bigdata.ministep.cn/