RxSwift and the Secret of the Variadic DisposeBag

Use one of RxSwift’s newest features to dramatically clean up your code

Michael Long
The Swift Cooperative
3 min readFeb 8, 2019

--

My company has been using RxSwift for all new iOS projects for a while now, and we’ve come to appreciate it’s power, flexibility, and conciseness.

That said, there is one area where RxSwift is, shall we say, somewhat less than concise. Where, in point of fact, it’s downright redundant.

So today, let’s talk about Disposables and DisposeBags.

--

--

Michael Long
The Swift Cooperative

I write about Apple, Swift, and SwiftUI in particular, and technology in general. I'm also a Lead iOS Engineer at InRhythm, a modern digital consulting firm.