Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save alanpaivaa/5ce9c86573abe8d98f6a5a324591d2a8 to your computer and use it in GitHub Desktop.
Save alanpaivaa/5ce9c86573abe8d98f6a5a324591d2a8 to your computer and use it in GitHub Desktop.
_ = printSecondBoundary()
let intSequence = Observable<Int>.interval(.seconds(1), scheduler: MainScheduler.instance).share(replay: 2)
_ = intSequence.printNext("Subscription A")
delay(3) { _ = intSequence.printNext("Subscription B") }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment