Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | |
7 | 8 | 9 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | 18 | 19 | 20 |
21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 | 29 | 30 | 31 |
Tags
- Xcode
- SWIFT
- Clean Code
- combine
- 리펙토링
- RxCocoa
- Observable
- 애니메이션
- rxswift
- UITextView
- Human interface guide
- Refactoring
- 리펙터링
- tableView
- 스위프트
- uitableview
- uiscrollview
- 리팩토링
- Protocol
- collectionview
- 클린 코드
- swiftUI
- map
- clean architecture
- HIG
- swift documentation
- ribs
- MVVM
- ios
- UICollectionView
Archives
- Today
- Total
목록2024/01/26 (1)
김종권의 iOS 앱 개발 알아가기
[iOS - swift] DataSource 리펙토링 - Section과 Item을 enum으로 놓고 dictionary로 관리하기
일반적인 DataSource 관리 Section이 여러개이고 Item도 여러개인 경우, 보통 dataSource를 2차원 배열로 하거나, Section과 Item을 갖는 struct를 만들어서 관리 class ViewController: UIViewController { struct Section { var title: String var items: [String] } var sections: [Section] = [ Section(title: "header is a", items: ["A1", "A2"]), Section(title: "header is b", items: ["B1", "B2"]), ] let tableView: UITableView = {...} } extension ViewCont..
Refactoring (리펙토링)
2024. 1. 26. 01:38