Skip to content

feat(auth): add useLogin/useLogout hooks - #444

Merged
zigzagdev merged 2 commits into
feat/user-loginfrom
feat/user-login-hooks
Jul 27, 2026
Merged

zigzagdev merged 2 commits into
feat/user-loginfrom
feat/user-login-hooks

Conversation

@zigzagdev

Copy link
Copy Markdown
Owner

Summary

  • Add useLogin / useLogout hooks (loading/error state, AbortController-based cancellation, token persistence)
  • Add the shared auth context this hooks feature and the rest of the app read from: AuthProvider + useAuth (shared/auth/AuthProvider.tsx / AuthHooks.ts), and token-storage.ts (localStorage-backed bearer token storage)
  • useLogin now routes form values through toLoginRequest before calling the API

Related

Closes #437

Test plan

  • npx tsc --noEmit
  • npx jest src/app/features/auth/hooks

@zigzagdev zigzagdev self-assigned this Jul 27, 2026
@zigzagdev zigzagdev linked an issue Jul 27, 2026 that may be closed by this pull request
3 tasks
Base automatically changed from feat/user-login-mapper to feat/user-login July 27, 2026 13:06

@zigzagdev zigzagdev left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok

@zigzagdev
zigzagdev merged commit f43983d into feat/user-login Jul 27, 2026
1 check passed
@zigzagdev
zigzagdev deleted the feat/user-login-hooks branch July 27, 2026 13:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: useLoginフックを追加

1 participant