Skip to content

Instantly share code, notes, and snippets.

@eSpecialized eSpecialized/rxy.swift
Last active Apr 14, 2018

Embed
What would you like to do?
Simple RxSwift
import RxSwift
let bag = DisposeBag()
let publisher = PublishSubject<Int>()
publisher
.ignoreElements()
.subscribe(onCompleted: {
print("completed")
})
.disposed(by: bag)
publisher.onNext(3)
publisher.onCompleted()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.