thanks for the article let me ask about following case deleteUser = id=() => {…
Dima Kishmareishvili

all of this cases you need to think it in this way: react send props to the child … so on every re render will check if a props change… defining an arrow function inside a prop will always be a different function… in your case calling the function depends of the type of return… but in this case will return a pointer to something in memory and that means it is something new all the time… so again… think it like “oh I’m sending something new inside a prop that means react will re render” I hope this clarify your problem

Like what you read? Give Gonzalo Santomé a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.