Skip to content

Commit fd4da1d

Browse files
refactor: avoid synchronous state updates in useEffect (#1408)
Fixes a cascading render warning caused by calling `handleLogin` synchronously inside a mounting effect. Changes: - Decoupled the API login logic from the manual UI loading trigger. - Initialized `isLoggingIn` state based on URL parameters to prevent an immediate rerender on mount. - Extracted `performLogin` to handle the side effect without triggering synchronous state updates. Signed-off-by: Jasmina <jasmina.piric@secomind.com> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
1 parent ce930ba commit fd4da1d

3 files changed

Lines changed: 231 additions & 215 deletions

File tree

0 commit comments

Comments
 (0)