Replaced the manual useState(data/loading/error) + load useCallback + useEffect (and the R3 request-seq guard) with a useAnalyticsSummary(params) query hook. React Query now handles caching, dedup, cancellation, and out-of-order responses via the params-encoded key; keepPreviousData keeps the last result visible while a new month/filter loads. Refresh -> refetch; the redundant page-load error toast is dropped in favor of the existing inline error state. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| components | ||
| contexts | ||
| hooks | ||
| lib | ||
| pages | ||
| public/img | ||
| App.jsx | ||
| api.js | ||
| index.css | ||
| main.jsx | ||