Will It Vibe logoWill It Vibe?
REACT-008Medium severity-8 points

useEffect without a dependency array

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 useEffect call with no second argument re-runs its effect after every render, which commonly causes redundant fetches, event listeners, or an infinite update loop when the effect also sets state.

Why it matters

A useEffect with no dependency array runs its effect after every single render. If the effect fetches data, adds a listener, or sets state, that means a request or a listener on every render, or an infinite render loop when the effect updates state that triggers another render. This is one of the most common causes of runaway React apps.

How to fix it

Add a dependency array as the second argument. Use [] if the effect should run once on mount, or list exactly the values the effect reads. Let the React hooks eslint rule (eslint-plugin-react-hooks) fill in the correct dependencies rather than guessing.

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

Related Code Quality & Syntax checks