[#487] ProfileViewModel 생성 및 생명주기를 개선한다#497
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Code Review
이번 풀 요청은 MainView에서 탭 전환 시 코디네이터를 통해 프로필 데이터를 가져오도록 .onAppear 이벤트를 .fetchData 액션으로 리팩토링하고, 관련 테스트 코드, 로컬라이징 문자열 및 DevLog.drawio 다이어그램을 업데이트합니다. 리뷰 피드백에서는 탭을 전환할 때마다 fetchData가 무조건 호출되어 불필요한 네트워크 요청이 발생하는 성능 문제를 지적하며, 데이터가 비어있을 때만 요청을 수행하도록 개선할 것을 제안했습니다.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
🔗 연관된 이슈
🎯 의도
📝 작업 내용
📌 요약
onAppear에서MainView의 탭 선택 변경 시점으로 이동ProfileViewModel의 루트 진입 액션명을onAppear에서fetchData로 변경Localizable.xcstrings추출 상태 메타데이터 동기화docs/DevLog.drawio시퀀스 다이어그램 수정🔍 상세
MainView에서selectedTab변경 시.profile선택에 대해profileViewCoordinator.fetchData()호출 추가ProfileView의.onAppear { coordinator.viewModel.send(...) }제거ProfileViewCoordinator.fetchData()추가 및 내부 호출을viewModel.send(.fetchData)로 정리ProfileViewModel.Action의onAppear를fetchData로 변경하고 reducer 분기명 정리DeleteWebPageTests에서 변경된HomeViewModel액션명(.fetchData) 반영Localizable.xcstrings의 키 재정렬 및extractionState메타데이터 갱신 반영📸 영상 / 이미지 (Optional)
2026-05-27.9.47.57.mov
2026-05-27.9.53.22.mov