Skip to content
Browse files

Add Example gif

  • Loading branch information...
freak4pc committed Jun 11, 2019
1 parent 0f5b2b1 commit 1e56d0d0d0c0b4f233c58dfa1611e084dc1b70e7
Showing with 39 additions and 7 deletions.
  1. +39 −7
  2. BIN Resources/example.gif
@@ -5,7 +5,7 @@
<br /><br />
<a href="" target="_blank"><img src=""></a>
<a href="" target="_blank"><img src=""></a><br />
<img src="" />
<img src="" />
@@ -14,13 +14,45 @@ RxCombine provides bi-directional type bridging between [RxSwift](https://github
**Note**: This is highly experimental, and basically just a quickly-put-together MVP. I gladly except PRs, ideas, opinions, or improvements. Thank you ! :)
# Basic Examples
Check out the Example App in the **ExampleApp** folder.
<p align="center"><img src="Resources/example.gif" width="400"></p>
# Installation
## CocoaPods
Add the following line to your **Podfile**:
pod 'RxCombine'
## Swift Package Manager
Add the following dependency to your **Package.swift** file:
.package(url: "", from: "1.0.0")
## Carthage
No Carthage support yet. I hope to have the time to take care of it soon.
Feel free to open a PR !
# I want to ...
## Use RxSwift in my Combine code
RxCombine provides several helpers and conversions to help you bridge your existing RxSwift types to Combine.
* `Observable` (and other `ObservableConvertibleType`s) have a `publisher` property which which returns a `AnyPublisher<Element, Swift.Error>` mirroring the underlying `Observable`.
**Note**: If you want to learn more about the parallel operators in Combine from RxSwift, check out my [RxSwift to Combine Cheat Sheet]( *(or on [GitHub](*.
* `Observable` (and other `ObservableConvertibleType`s) have a `publisher` property which returns a `AnyPublisher<Element, Swift.Error>` mirroring the underlying `Observable`.
let observable = Observable.just("Hello, Combine!")
@@ -45,14 +77,13 @@ relay.send(2)
## Use Combine types in my RxSwift code
## Use Combine in my RxSwift code
RxCombine provides several helpers and conversions to help you bridge Combine code and types into your existing RxSwift codebase.
* `Publisher`s have a `asObservable()` method, providing an `Observable<Output>` mirroring the underlying `Publisher`.
// A publisher publishing numbers from 0 to 100.
let publisher = AnyPublisher<Int, Swift.Error> { subscriber in
(0...100).forEach { _ = subscriber.receive($0) }
subscriber.receive(completion: .finished)
@@ -74,12 +105,13 @@ publisher.asObservable()
.bind(to: relay) // Disposable
.susbcribe(to: relay.asAnyObserver()) // Disposable
.susbcribe(relay.asAnyObserver()) // Disposable
# Future ideas
# Future ideas
* Add CI / Tests
* Carthage Support
* Bridge SwiftUI with RxCocoa/RxSwift
* Partial Backpressure support, perhaps?
* ... your ideas? :)
BIN +766 KB Resources/example.gif
Binary file not shown.

0 comments on commit 1e56d0d

Please sign in to comment.
You can’t perform that action at this time.