Hacker News new | past | comments | ask | show | jobs | submit login

> But I also don’t understand, why react renders all child components if the parent renders. As long as their props stay the same, they should just stay as they are.

It "renders" all child components if their parent renders in order to check if their props have changed or not.

If the component has not actually changed, it does not actually re-draw it.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: