React- Removing a list item
Im just trying to remove the list item from the list using onClick with a button. I was following a book called Road to React but it still doesn’t update the state of the list(returns new list without the deleted item).It appears to me that im doing something wrong in the removePerson function and using the filter function but I just cant wrap my head around what it is.