Почему моя функция возвращает туже таблицу без изминенного item?
const start = (table: any) => {
for ( let i = 0; i< 5; i++) {
if (i === 1) {
// @ts-ignore
table[i].props.children.map( (item, index) => {
if (index == 1) {
console.log('item before', item)
item = React.cloneElement(item, {className: 'blue'}, null)
console.log('item after', item)
}
})
}
}
return table
}