Skip to content

chore: 에셋 정리 및 패키지 관리 방법 변경#694

Open
mini-min wants to merge 9 commits into
TeamNADA:developfrom
mini-min:feature/#690
Open

chore: 에셋 정리 및 패키지 관리 방법 변경#694
mini-min wants to merge 9 commits into
TeamNADA:developfrom
mini-min:feature/#690

Conversation

@mini-min

Copy link
Copy Markdown
Member

🌴 PR 요약

🌱 작업한 브랜치

🌱 작업한 내용

제대 후 나다에서 처음 날리는 PR이네요.....설렙니다.
용량 줄이기 작업이 너무 무거워져서 쪼개려고 먼저 PR 올립니다!

1. 에셋 정리

  • 에셋 폴더링 조금 보기 좋게 묶어놨습니다!
  • 예전에는 사용했지만, 지금은 사용하는 이미지/아이콘들 제거했습니다.
  • svg로 사용할 수 있는 아이콘, 이미지들은 png에서 svg 파일로 변경했습니다. (SVG는 PNG에 비해 용량이 작다, 확대/축소해도 이미지의 품질이 변하지 않는다는 장점을 가지고 있습니다.)

2. 패키지 관리 방법 변경 (Cocoapods -> SPM)

  • 과거 나다 프로젝트를 시작했을 때만 하더라도 SPM은 지원하지 않는 라이브러리가 많다는 점 때문에 자연스럽게 세미나에서 배운 CocoaPods를 활용해서 패키지를 관리하고 있었습니다.
  • 하지만, 24년 현재 SPM은 라이브러리 지원에 문제가 없는 것으로 판단. Apple에서 공식 지원하는 의존성 관리 도구를 사용하는 것이 낫다고 생각했습니다.
  • CocoaPods는 빌드 속도 증가, 무엇보다도 라이브러리를 프로젝트에 포함시킨다는 점 때문에 기존 앱 용량을 많이 잡아먹고 있다는 문제가 있었습니다.
  • 즉, 정리하면 빌드 속도, 앱 용량, 의존성 관리 점에서 SPM을 사용하는 것으로 변경했습니다. 추가적인 의견있으시면 선배님들의 조언 부탁드립니다 ^__^

이후에 어떤 작업?

  • 폰트 파일 역시 불필요하게 많은 앱 용량을 잡아먹고 있어, 폰트 파일을 줄여보겠습니다.
  • 처음 몇 개의 버튼이 이미지로 박아놓은 것들이 있어서 해당 컴포넌트들 에셋 지우고, 코드로 구현하겠습니다.

📮 관련 이슈

@mini-min mini-min added Minjae 🐻‍❄️ 민재 강남1타강사 작업 Del 쓸모없는 코드 삭제 Chore 그 이외의 잡일, production code의 변경은 없음 labels Mar 25, 2024
@mini-min mini-min requested review from dlwns33 and hyun99999 March 25, 2024 04:36
@mini-min mini-min self-assigned this Mar 25, 2024

@hyun99999 hyun99999 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

commit 2860d5d

에서 UIKit 을 추가했는데 이유가 있을까요??

@hyun99999 hyun99999 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

commit f1670cd

유지보수할 때 항상 고민되는 것이 화면에 대한 삭제인 것 같아요..! 만들어는 뒀는데 혹시 다시 쓰지는 않을까 하는거죵
그런데 현재 새롭게 카드 궁합 뷰로 대체하고 있으니 괜찮을 것 같아요!! 감사합니다~

@hyun99999 hyun99999 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SPM 으로 관리하는 방법 좋은 것 같아요! 그런데 SPM 에서 지원하지 않는 것들이 꽤나 많아서 선별해서 전환해야 할 것 같습니다...!! alamofire 만 우선 변경하실 건가요? 지금 커밋 내역에는 해당 기록이 없는데 확인할 수 있을까용?

Comment thread Beta.xcconfig
// Configuration settings file format documentation can be found at:
// https://help.apple.com/xcode/#/dev745c5c974

#include "Pods/Target Support Files/Pods-NADA-iOS-forRelease/Pods-NADA-iOS-forRelease.debug.xcconfig"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

나머지 cocoapods 에서 제공하는 프레임워크는 필요할텐데 이렇게 삭제 해도 괜찮나용?

@hyun99999 hyun99999 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

더 나은 프로젝트를 위해서 노력해주셔서 감사합니다~~
이미지 에셋을 SVG 로 바꾸거나 폰트를 줄이는 방법 등 용량을 줄이기 위해 좋은 방법이 많네요..!
그리고 SPM 을 도입하는 것도 좋아요!!
고생하셨습니다..!! 코멘트 확인 부탁드려요~ 👍

@dlwns33 dlwns33 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

남아있던 코드들을 지우니 한층 프로젝트가 깔끔해진 것 같아요!
사실 오래된 프로젝트들의 문제점 중 하나가 레거시 코드가 많이 있다는 점인데,
이렇게 새로운게 생길때마다 프로젝트 정리를 한번씩 해주면 레거시 코드들이 남아있지 않아서 좋은 것 같네요~ 하나하나 고치느라 진짜 수고했담!

Comment on lines +602 to +608
self.timesLeft = 600 - (interval.second ?? 0)
print("✅ now: ", Date())
print("✅ activated Time: ", nearByUUIDResponse.activeTime?.toDate())
print("✅ timesleft: ", self.timesLeft)
self.nearByTimeLabel.text = ""
self.setCardActivationUI(with: nearByUUIDResponse.isActive, secondsLeft: self.timesLeft ?? 0)
self.setCardActivationUI(with: nearByUUIDResponse.isActive,
secondsLeft: self.timesLeft)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

제가 요 부분을 개발했을때 굉장히 급하게 개발했던 것으로 기억합니다...
저 이니셜 값이 없어도 잘 돌아가던가요..?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Chore 그 이외의 잡일, production code의 변경은 없음 Del 쓸모없는 코드 삭제 Minjae 🐻‍❄️ 민재 강남1타강사 작업

Projects

None yet

Development

Successfully merging this pull request may close these issues.

delete: 쓸모 없는 코드, 에셋 삭제

3 participants