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 |
Tags
- 리펙토링
- Human interface guide
- Observable
- rxswift
- SWIFT
- 클린 코드
- 리펙터링
- clean architecture
- map
- swift documentation
- Refactoring
- Protocol
- ios
- swiftUI
- ribs
- tableView
- collectionview
- uiscrollview
- combine
- uitableview
- Xcode
- 리팩토링
- UICollectionView
- UITextView
- MVVM
- RxCocoa
- Clean Code
- 스위프트
- HIG
- 애니메이션
Archives
- Today
- Total
목록Cancellable (1)
김종권의 iOS 앱 개발 알아가기
[iOS - SwiftUI] Combine의 Cancellable (AnyCancellable) 사용 방법
목차) Combine - 목차 링크 Cancellable Combine 작업들을 취소할 수 있다는 의미를 가지고 있는 프로토콜 Combine에서는 이벤트 스트림을 action이라는 이름을 사용, action을 취소할 수 있는 프로토콜이 Cancellable이라는 의미 AnyCancellable final public class AnyCancellable : Cancellable, Hashable .sink로 이벤트를 구독하면 리턴값으로 AnyCancellable이 얻어지는데 이 값을 가지고 cancel()하여 언제든지 구독을 취소시킬 수 있는 기능 final class MyModel { @Published var number: Int init(number: Int) { self.number = numbe..
iOS Combine (SwiftUI)
2022. 9. 16. 22:42