-
Notifications
You must be signed in to change notification settings - Fork 0
[Feat] 소식 탭 배지 구현 및 프로필 탭 코디네이터 패턴 적용 #301
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
Conversation
1. 삭제를 먼저 서버에 요청 2. 성공 시, 유저 활동 정보 삭제 3. 성공 시, 유저 세션 삭제
- 애플 로그인 시, 아이디가 없는 건지 확인 필요
- 사용하지 않는 코드 삭제 - 중복 코드 제거
youz2me
left a comment
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.
고생하셨습니다!
| @Injected private var userSessionRepository: UserSessionRepository | ||
| @Injected private var userActivityRepository: UserActivityRepository |
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.
UserSession과 UserActivity의 범위가 모호할수도 있겠다는 생각이 드네요. 구현해두신 UserActivity 대로라면 UserSession의 notificationCount도 UserActivity로 옮겨야 할 것 같긴 한데... QA 이후에 해당 부분에 대해 조금 더 자세히 이야기해보고 리팩토링하면 좋을 것 같습니다.
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.
네 좋습니다!!
| func setupViewControllers() { | ||
| let useCase = viewModel.useCase |
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.
이 부분은 DIP를 위반할 수 있지 않을까요??
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.
어떤 부분에서 위반한다고 말씀하신 것인지는 모르겠으나, 하나의 인스턴스를 전부 프로토콜 타입으로 주입되기 때문에 리소스 절약 및 DIP를 준수하고 있다고 생각됩니다
- QuizCoordinator 사용하지 않는 메서드 주석 처리 - Xcode 프로젝트 파일 업데이트
- checkTodayQuizCompletion 메서드 추가 - fetchActiveUserSession으로 사용자별 퀴즈 완료 여부 확인 - 퀴즈 완료 시 NextQuizInfoViewController, 미완료 시 QuizViewController 표시
- QuizCoordinator 사용하지 않는 메서드 주석 처리 - Xcode 프로젝트 파일 업데이트
- checkTodayQuizCompletion 메서드 추가 - fetchActiveUserSession으로 사용자별 퀴즈 완료 여부 확인 - 퀴즈 완료 시 NextQuizInfoViewController, 미완료 시 QuizViewController 표시
👻 PULL REQUEST
📄 작업 내용
💻 주요 코드 설명
📌 UserSession, UserActivity
UserActivity로 분리하여 구현하였습니다.관심사의 분리
UserSession은 계정 정보 등 핵심 정보를 관리하는 반면 유저 활동 기록에 해당하는 내용을 다루려 했기 때문에 빈도와 중요도가 다르다고 생각했습니다.독립적인 확장성 확보
UserSession에 추가하는 것은 해당 모델에 의존하는 모든 코드에 영향을 미칠 수 있습니다.커스텀 Codable 구현
UserActivity를 개발해 나가는 과정에서, 저는 초기에 큐레이션 아이디에 대해서만 다루었습니다..zero를 할당하도록 하였습니다.👉🏼 UserActivity 코드
📌 계정 삭제(탈퇴) 시 대응
코디네이터 패턴 적용
MyProfileView부터 시작되는 프로필 탭에 대해서 코디네이터 패턴을 적용하였습니다.계정 삭제 시 대응
UserActivity) 삭제하기UserSession) 삭제하기👀 리뷰어에게 전달할 사항
하, 제가 300번째 이슈라니✅ 이번 PR에서 이런 부분을 중점적으로 체크해주세요!
잠깐 확인하고 갈까요?
들여쓰기를 5번 이하로 준수했는지, 코드 가독성이 적절한지 확인해주세요.
한 줄당 120자 제한을 준수했는지 확인해주세요.
MARK 주석이 정해진 순서와 형식에 맞게 작성되었는지 확인해주세요.
반복되는 상수 값이 있는지, 있다면 Constant enum으로 분리되어 있는지 확인해주세요.
삼항 연산자가 길어질 경우 적절히 개행되어 있는지 확인해주세요.
조건문에서 중괄호가 올바르게 사용되었는지 확인해주세요.
라이브러리 import가 퍼스트파티와 서드파티로 구분되고 알파벳순으로 정렬되었는지 확인해주세요.
용량이 큰 리소스나 호출되지 않을 가능성이 있는 프로퍼티에 lazy var가 적절히 사용되었는지 확인해주세요.
메모리 누수 방지를 위한 weak 참조가 필요한 곳에 적용되었는지 확인해주세요.
도메인 로직과 UI 로직이 적절히 분리되어 있는지 확인해주세요.
🔗 연결된 이슈