Parent tracking issue: #1455
Summary
Resolve all 36 `@eslint-react/use-state` warnings, which flag `useState` calls where the initial value is an expensive expression that runs every render instead of just once.
Fix pattern
```tsx
// before — computes on every render
const [items, setItems] = useState(expensiveCompute());
const [map, setMap] = useState(new Map([['a', 1]]));
// after — only computes on mount
const [items, setItems] = useState(() => expensiveCompute());
const [map, setMap] = useState(() => new Map([['a', 1]]));
```
The rule fires whenever the initial value is a function call, object/array/Map/Set literal, or any non-primitive expression.
Scope
Production code (`client/src/`).
Acceptance Criteria
Risk
Very low. Mechanical wrap-in-arrow-fn.
Parent tracking issue: #1455
Summary
Resolve all 36 `@eslint-react/use-state` warnings, which flag `useState` calls where the initial value is an expensive expression that runs every render instead of just once.
Fix pattern
```tsx
// before — computes on every render
const [items, setItems] = useState(expensiveCompute());
const [map, setMap] = useState(new Map([['a', 1]]));
// after — only computes on mount
const [items, setItems] = useState(() => expensiveCompute());
const [map, setMap] = useState(() => new Map([['a', 1]]));
```
The rule fires whenever the initial value is a function call, object/array/Map/Set literal, or any non-primitive expression.
Scope
Production code (`client/src/`).
Acceptance Criteria
Risk
Very low. Mechanical wrap-in-arrow-fn.