[英]React MUI Error Missing "key" prop for element in array react/jsx-key
{
field: 'deletedAt',
headerName: 'DeleteAt',
type: 'actions',
width: 200,
editable: false,
getActions: () => [<GridActionsCellItem icon={<DeleteIcon />} label="Delete" />],
},
return (
<div style={{ height: 720, width: '100%' }}>
<DataGridPro
rows={customizings}
columns={columns}
getRowId={(row) => row._id}
experimentalFeatures={{ newEditingApi: true }}
components={{ Toolbar: GridToolbar }}
initialState={{ pinnedColumns: { right: ['actions'] } }}
/>
</div>
);
I want to add this icon to the contents of the datagrid table, but I am getting a back key error.我想将此图标添加到数据网格表的内容中,但出现返回键错误。 How can I solve?
我该如何解决?
Antwort: Name of field must be actions Antwort:字段名称必须是动作
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.