Feature/#37 - NavigationSplitView 기본 틀 구성 및 AppFeature 연결 - #39
Conversation
Walkthrough
Changes메인 화면 네비게이션
Estimated code review effort: 3 (Moderate) | ~25 minutes Sequence Diagram(s)sequenceDiagram
participant AppView
participant AppFeature
participant MainView
participant MainFeature
AppView->>AppFeature: .task 액션 전송
AppFeature->>MainFeature: main child action 라우팅
AppView->>MainView: main 상태로 scoped store 전달
MainView->>MainFeature: .task 액션 전송
MainFeature->>MainView: NavigationSplitView 상태 제공
Possibly related PRs
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
Projects/DVPresentation/Sources/Features/Main/MainView.swift (1)
17-20: 🩺 Stability & Availability | 🔵 Trivial | ⚡ Quick win뷰 라이프사이클과 Effect 취소 동기화 ♻️
.task블록 안에서 단순히store.send를 동기적으로 호출하면, 뷰가 사라질 때 관련된 TCA Effect가 자동으로 취소되지 않습니다.
뷰의 생명주기와 Effect의 라이프사이클을 안전하게 동기화하려면await ... .finish()패턴을 사용하는 것이 좋습니다. 만약 단순히 뷰가 나타날 때 동기적인 액션만 전달하려는 목적이라면.onAppear가 더 명확한 의도를 전달할 수 있습니다.💡 제안하는 수정안
var body: some View { content - .task { store.send(.task) } + .task { await store.send(.task).finish() } }🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@Projects/DVPresentation/Sources/Features/Main/MainView.swift` around lines 17 - 20, Update the .task modifier in MainView.body so the lifecycle-bound task awaits the store send and its completion, using the await … .finish() pattern to keep related TCA effects cancellable when the view disappears; if the action is intentionally synchronous only, replace this modifier with .onAppear and preserve the existing .task action behavior.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@Projects/DVPresentation/Sources/Features/Main/MainView.swift`:
- Around line 17-20: Update the .task modifier in MainView.body so the
lifecycle-bound task awaits the store send and its completion, using the await …
.finish() pattern to keep related TCA effects cancellable when the view
disappears; if the action is intentionally synchronous only, replace this
modifier with .onAppear and preserve the existing .task action behavior.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 47663ba7-bae3-48f8-b25f-3f65b7368044
📒 Files selected for processing (7)
Projects/DVPresentation/Sources/Features/AppFeature.swiftProjects/DVPresentation/Sources/Features/AppView.swiftProjects/DVPresentation/Sources/Features/Main/MainFeature.swiftProjects/DVPresentation/Sources/Features/Main/MainView.swiftProjects/DVPresentation/Sources/ProjectSecretRelationDemoView.swiftProjects/DVPresentation/Sources/SecretUseCaseDemoView.swiftProjects/Devault/Sources/ContentView.swift
💤 Files with no reviewable changes (3)
- Projects/DVPresentation/Sources/SecretUseCaseDemoView.swift
- Projects/Devault/Sources/ContentView.swift
- Projects/DVPresentation/Sources/ProjectSecretRelationDemoView.swift
✨ What’s this PR?
📌 관련 이슈 (Related Issue)
🧶 주요 변경 내용 (Summary)
MainFeature/MainView신규 생성 — NavigationSplitView 3-column (sidebar / content / detail) 기본 틀 구성AppFeature에Scope로MainFeature자식 리듀서 연결,AppView에서MainView로 라우팅BindingReducer적용으로$store.columnVisibility직접 바인딩 지원📸 스크린샷 (Optional)
🧪 테스트 / 검증 내역
💬 기타 공유 사항
🙇🏻♀️ 리뷰 가이드 (선택)
Summary by CodeRabbit
새로운 기능
변경 사항