Anti-patterns' Using Indexes as key section is based on an outdated article and is no longer correct.
Keys should be stable, predictable, and unique. Unstable keys (like those produced by Math.random()) will cause many component instances and DOM nodes to be unnecessarily recreated, which can cause performance degradation and lost state in child components.
Anti-patterns' Using Indexes as key section is based on an outdated article and is no longer correct.
A more entertaining explanation can be found here (credit to Lin Clark).
Suggestions:
obj.id
should be unique and repeatable among all siblings@vasanthk I'm happy to open a PR for this, if you are satisfied with the suggestions I made 👍