-
Notifications
You must be signed in to change notification settings - Fork 1
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
리팩토링 (밀봉, 개봉, 홈, Capsule) #129
Conversation
# Conflicts: # SpaceCapsule/SpaceCapsule/Scene/TabBar/CapsuleAccess/CapsuleOpen/CapsuleOpenView.swift # SpaceCapsule/SpaceCapsule/Scene/TabBar/CapsuleAccess/CapsuleOpen/CapsuleOpenViewController.swift # SpaceCapsule/SpaceCapsule/Scene/TabBar/CapsuleAdd/CapsuleClose/CapsuleCloseView.swift # SpaceCapsule/SpaceCapsule/Scene/TabBar/CapsuleList/CapsuleListViewModel.swift # SpaceCapsule/SpaceCapsule/Scene/TabBar/CapsuleList/Components/ListCapsuleCell.swift # SpaceCapsule/SpaceCapsule/Scene/TabBar/CapsuleMap/CapsuleMapCoordinator.swift # SpaceCapsule/SpaceCapsule/Scene/TabBar/Home/Components/HomeCapsuleCell.swift # SpaceCapsule/SpaceCapsule/Scene/TabBar/Home/HomeCoordinator.swift # SpaceCapsule/SpaceCapsule/Scene/TabBar/Home/HomeViewModel.swift
# Conflicts: # SpaceCapsule/SpaceCapsule.xcodeproj/project.pbxproj # SpaceCapsule/SpaceCapsule/Scene/TabBar/CapsuleAccess/CapsuleOpen/CapsuleOpenView.swift # SpaceCapsule/SpaceCapsule/Scene/TabBar/CapsuleAdd/CapsuleClose/CapsuleCloseView.swift
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 configure() { | ||
private func configure() { | ||
backgroundColor = .themeGray100 | ||
layer.shadowOffset = FrameResource.capsuleCellShadowOffset | ||
layer.shadowRadius = FrameResource.capsuleCellShadowRadius | ||
layer.shadowOpacity = FrameResource.capsuleCellShadowOpacity | ||
layer.cornerRadius = width / 2 | ||
} | ||
|
||
func addSubViews() { | ||
private func addSubViews() { | ||
[imageView].forEach { | ||
addSubview($0) | ||
} | ||
} | ||
|
||
func makeConstraints() { | ||
private func makeConstraints() { |
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.
저희 BaseView 프로토콜 사용 안하신데는 이유가 있나요?
분리된 컴포넌트라서 그런거라면 이해 할 수 있을 것 같아요!
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.
말씀하신것처럼 분리된 컴포넌트이기도 하고 저 메소드들은 private 해야한다고 생각해서 이렇게 했습니다....!
|
||
return button | ||
}() | ||
let doneButton = ThemeButton(title: "완료") |
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.
항상 컴포넌트로 분리 해주셔서 너무 감사드려요
귀찮은 일 매번 선뜻 나서서 해주시는 점 리스펙합니다!
꼭 입사 관계자들이 알아 주셨으면!!!
thumbnailImageURL: capsule.images.first, | ||
thumbnailImageURL: capsule.images.first ?? "", |
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.
옵셔널을 줄이서 없으시려는 효과가 있나요?
간단히 설명 부탁드려요!
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.
원래 해당 프로퍼티가 optional 이었을때는 url 을 이용해 이미지를 그리는 부분에서 바인딩을 하고, nil 이면 아예 이미지를 그리지 않고 있었더라구요!
이미지를 그리는 경우에 url 을 구성할 string 이 유효하지 않다면 placeholder 이미지를 보여주기 때문에 굳이 바인딩하는 과정을 거칠 필요가 없다고 생각했습니다.
그래서 optional 을 View 로 넘기기보다는 만약 nil 이라면 차라리 빈 문자열을 넘겨서 유효한 url 이 되지 않게 하자! 라는 의도였습니당
제출 전 필수 확인 사항:
작업 내용: