-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Refactor] SettingView 리팩토링 / SettingReducer 구현 #81
Merged
+343
−201
Merged
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
b6738f1
[#78] Empty SettingReducer 구현
CJiu01 6b08916
[#78] 기존 SettingView->Legacy 로 변경
CJiu01 26a1f4d
[#78] SettingView UI구현(Legacy 코드)
CJiu01 4ba312c
[#78] home네비게이션 Legacy로 임시 변경
CJiu01 36040a7
[#78] component 네이밍 변경
CJiu01 8f24b80
[#78] WebView 사용을 위한 권한 추가
CJiu01 0b7575a
[#78] WebReducer 구현
CJiu01 0575726
[#78] WebView 구현
CJiu01 5c30f27
[#78] togglePushAuthorization 관련 action 정의
CJiu01 a78f5d0
[#78] SettingView: send호출 enum 처리 및 alert 추가
CJiu01 1803f78
[#78] webView 이동을 위한 path 추가
CJiu01 7106285
[#78] SettingView NavigationStack 추가
CJiu01 b042205
[#78] WebReducer.state Equatable 프로토콜 준수
CJiu01 ca71702
[#78] PresentationAction 방식으로 Alert 리팩토링
CJiu01 6cf578f
[#78] 로그아웃 완료시 토스트 띄움
CJiu01 237ef7f
[#78] Path extension으로 분리
CJiu01 5ac249d
[#78] 로그아웃시, AppReducer .logout 액션 정의
CJiu01 0ceec53
[#78] AppReducer.State 옵셔널 처리
CJiu01 0a97298
[#78] alert의 logout탭 클릭시, Login으로 이동
CJiu01 3000517
[#78] LegacySettingView 제거
CJiu01 7bceaf1
Merge branch 'develop' into refactor/#78
CJiu01 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
Soomsil-USaint/Application/Feature/Setting/Core/WebReducer.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
// | ||
// WebReducer.swift | ||
// Soomsil-USaint | ||
// | ||
// Created by 최지우 on 1/27/25. | ||
// | ||
|
||
import Foundation | ||
|
||
import ComposableArchitecture | ||
|
||
@Reducer | ||
struct WebReducer { | ||
|
||
@ObservableState | ||
struct State: Equatable { | ||
let url: URL | ||
} | ||
|
||
enum Action { | ||
case dismiss | ||
} | ||
|
||
@Dependency(\.dismiss) var dismiss | ||
|
||
var body: some ReducerOf<Self> { | ||
Reduce { state, action in | ||
switch action { | ||
case .dismiss: | ||
return .run { _ in | ||
await self.dismiss() | ||
} | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
사소한 부분이지만, Alert의 Action도 버튼을 누른 것이라면,
logoutTapped
와 같이 "Tapped"를 붙이는 것은 어떤가요?추후에 CoreData 내 정보를 삭제하기 위해 GradeClient 및 StudentClient의 delete를 실행할 때, Response를 받는 부분과 구분을 확실하게 하려면 네이밍을 확실하게 구분짓는게 좋을 것 같아요!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
말씀대로 네이밍을 통해 혼선을 방지할 수 있을 것 같네요!
#84 이슈에서 반영해놓겠습니다!