-
Notifications
You must be signed in to change notification settings - Fork 433
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add interop with Apple's Combine framework #741
Comments
I'm looking into implementing a compatibility layer so that Combine can run on iOS 12 using ReactiveSwift as the underlying framework. Is this similar to what you're proposing, or more for just something that can wrap Combine types in ReactiveSwift types and vice versa? |
I was suggesting something that bridges the types—similar to ReactiveObjCBridge. |
Sounds like an awesome idea! Any updates on this? |
Over the weekend I spent some time to throw together a quick implementation of this, which can be found here: https://github.com/simba909/ReactiveCombineBridge Please note that this needs (probably a lot..) more work, but in my quick testing it seems to work for the most common use cases:
Feedback/issues/PRs are more than welcome, and if there's interest in the long run to bring this work over to ReactiveCocoa I'd be more than happy to migrate it 👍 |
Since Combine ships as a system framework not requiring entitlements, the interoperability layer can be integrated directly in the ReactiveSwift library (provided that weak linkage in Swift works as expected). My rough plan is:
|
Any updates on this? Would love to see this happen. |
I’d also like to ask whether there are plans to add a Combine bridge in the foreseeable future. Or should I rather build the necessary pieces for the purpose of my app myself? |
Hello. 👋 Thanks for opening this issue. Due to inactivity, we will soft close the issue. If you feel that it should remain open, please let us know. 😄 |
As far as I'm aware, Apple hasn't addressed whether Combine will (a) be open source or (b) be cross-platform. So even beyond the current apps that use and depend on ReactiveSwift, I don't think ReactiveSwift is going anywhere for the time being.
But we should build an interop layer for converting between ReactiveSwift and Combine. This should be helpful for apps that want to transition from one library to the other. But it should also help for using SwiftUI from apps that currently use ReactiveSwift.
The text was updated successfully, but these errors were encountered: