With following code:
class MyView: ASDisplayNode {
let data = BehaviorRelay<Section>
override func didLoad() {
super.didLoad()
data.asDriver()
.map({ [$0] })
.drive(collectionView.rx.items(dataSource: dataSource))
.disposed(by: disposeBag)
}
}
The app will be crash when dismissed view controller because ASDisplayNode was dealloc
in background thread.
With following code:
The app will be crash when dismissed view controller because ASDisplayNode was dealloc
in background thread.