Why using an index value for a React key is a bad idea | Veera

Solid reasoning – with a clear example – of the potential dangers of using an array index as the key value in ReactJS. Not something I'd ever considered (and something I do a lot) but makes sense.

Explore Other Notes

Newer

Super Tiny Icons

A collection of hyper-optimised SVG logos for social media, popular websites, and tech companies. Every logo, whether in PNG or SVG form, is less than 1kb in size and have a base scale of […]

Older

Cube CSS

I think there's some real merit to Andy's ideas behind Cube CSS. It's a middle-ground between everything-in-JS or BEM that throw out the cascade entirely and the free-for-all that can happen if you […]
  • Solid reasoning – with a clear example – of the potential dangers of using an array index as the key value in ReactJS. Not something I'd ever considered (and something I do a <em>lot</em>) but [&#8230;]
  • Murray Adcock.
Journal permalink

Made By Me, But Made Possible By:

CMS:

Build: Gatsby

Deployment: GitHub

Hosting: Netlify

Connect With Me:

Twitter Twitter

Instagram Instragram

500px 500px

GitHub GitHub

Keep Up To Date:

All Posts RSS feed.

Articles RSS feed.

Journal RSS feed.

Notes RSS feed.