Skip to content

Instantly share code, notes, and snippets.

@WildStudio
Created July 5, 2019 11:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save WildStudio/adebe7e4a9c6ff0d52a18edcf92cd23b to your computer and use it in GitHub Desktop.
Save WildStudio/adebe7e4a9c6ff0d52a18edcf92cd23b to your computer and use it in GitHub Desktop.
Combine: Cancellable Publisher
let cancellablePublisher = somePublisher.sink { data in
// do something
}
cancellablePublisher.cancel()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment