I have below code
case 'COMPLETE_TODO' :
state.todos[state.todos.findIndex((obj => obj.id == action.value))].status = "COMPLETED"
return {
...state,
todos: state.todos
}
I feel like an array is not taken as a modified array because just a property of one single element has been updated.
Any idea?
Thanks