Awesome Open Source
Awesome Open Source


codecov Language Cocoapods

Open-source implementation of Apple's Combine framework for processing values over time.

The main goal of this project is to provide a compatible, reliable and efficient implementation which can be used on Apple's operating systems before macOS 10.15 and iOS 13, as well as Linux, Windows and WebAssembly.

CI Status
Compatibility tests


OpenCombine contains three public targets: OpenCombine, OpenCombineFoundation and OpenCombineDispatch (the fourth one, COpenCombineHelpers, is considered private. Don't import it in your projects).

OpenCombine itself does not have any dependencies. Not even Foundation or Dispatch. If you want to use OpenCombine with Dispatch (for example for using DispatchQueue as Scheduler for operators like debounce, receive(on:) etc.), you will need to import both OpenCombine and OpenCombineDispatch. The same applies to Foundation: if you want to use, for instance, NotificationCenter or URLSession publishers, you'll need to also import OpenCombineFoundation.

If you develop code for multiple platforms, you may find it more convenient to import the OpenCombineShim module instead. It conditionally re-exports Combine on Apple platforms (if available), and all OpenCombine modules on other platforms. You can import OpenCombineShim only when using SwiftPM. It is not currently available for CocoaPods.

Swift Package Manager
Swift Package

To add OpenCombine to your SwiftPM package, add the OpenCombine package to the list of package and target dependencies in your Package.swift file. OpenCombineDispatch and OpenCombineFoundation products are currently not supported on WebAssembly. If your project targets WebAssembly exclusively, you should omit them from the list of your dependencies. If it targets multiple platforms including WebAssembly, depend on them only on non-WebAssembly platforms with conditional target dependencies.

dependencies: [
    .package(url: "", from: "0.13.0")
targets: [
        name: "MyAwesomePackage",
        dependencies: [
            .product(name: "OpenCombineFoundation", package: "OpenCombine"),
            .product(name: "OpenCombineDispatch", package: "OpenCombine")

OpenCombine can also be added as a SwiftPM dependency directly in your Xcode project (requires Xcode 11 upwards).

To do so, open Xcode, use FileSwift PackagesAdd Package Dependency…, enter the repository URL, choose the latest available version, and activate the checkboxes:

Select the OpenCombine and OpenCombineDispatch targets


To add OpenCombine to a project using CocoaPods, add OpenCombine and OpenCombineDispatch to the list of target dependencies in your Podfile.

pod 'OpenCombine', '~> 0.13.0'
pod 'OpenCombineDispatch', '~> 0.13.0'
pod 'OpenCombineFoundation', '~> 0.13.0'

Debugger Support

The file defines some lldb type summaries for easier debugging. These type summaries improve the way lldb and Xcode display some OpenCombine values.

To use, figure out its full path. Let's say the full path is ~/projects/OpenCombine/ Then the following statement to your ~/.lldbinit file:

command script import ~/projects/OpenCombine/

Currently, defines type summaries for these types:

  • Subscribers.Demand
  • That's all for now.



Related Awesome Lists
Top Programming Languages
Top Projects

Get A Weekly Email With Trending Projects For These Topics
No Spam. Unsubscribe easily at any time.
Swift (65,213
Xcode (12,432
Apple (8,383
Tvos (1,500
Watchos (1,089
Reactive Programming (1,084
Combine (396