Files
pvemanager/frontend/src
markmorado 32434e0ef3
Some checks failed
Deploy to Production / backend-tests (push) Has been cancelled
Deploy to Production / frontend-build (push) Has been cancelled
Frontend Checks / Build & typecheck (push) Has been cancelled
SonarCloud / SonarCloud Analysis (push) Has been cancelled
Deploy to Production / Trigger production update (push) Has been cancelled
refactor(frontend): drop setState-in-effect patterns
Replace all 57 react-hooks/set-state-in-effect sites with the patterns
React recommends:

- dialog forms reset while rendering when the dialog opens, instead of
  in an effect after a frame with stale values;
- forms filled from server data resync during render when a new
  response object arrives;
- default selections (server, node, storage, disk, user) are derived
  from the user's pick and the current list rather than written back
  into state.

This also fixes the migrate dialogs resetting the chosen target when
the guest status refreshed, and the image download dialog resetting
"convert to template" on every render while storages were loading.
Unstable `?? []` / `new Set()` hook dependencies are memoized.
2026-10-23 01:51:57 +05:00
..