Unstable list key from Math.random() / Date.now()
Part of Code Quality & Syntax, which counts for 20% of the overall score. When this check fires it deducts 8 points from that category, once per scan, no matter how many places it turns up.
What it detects
A key computed from Math.random() or Date.now() changes on every render, so React remounts each item every time: it destroys and recreates DOM and component state, loses focus, and tanks list performance.
Why it matters
A key built from Math.random() or Date.now() is different on every render, so React thinks every item is brand new and remounts the whole list each time. That destroys and recreates the DOM and component state for each row, loses input focus, restarts animations, and makes long lists slow.
How to fix it
Use a stable id that comes from the data, not one generated at render time. If the source data has no id, generate ids once when the data is created or loaded (not during render) and store them alongside the items. A random or time-based key is never correct.
The paid report includes a ready-to-paste prompt for your AI coding agent for every check it finds, pointed at the exact findings from your scan. See pricing
Does your repo trip this check?
Paste a GitHub URL or drop a project folder. Scans run in your browser and take seconds.
Scan your repo