feat: Add support for wasm compilation#2680
feat: Add support for wasm compilation#2680scottmarchant wants to merge 3 commits intoReactiveX:mainfrom
Conversation
|
|
||
| func dequeueNextAndSubscribe() { | ||
| if let next = queue.dequeue() { | ||
| // HACK: concatMap depends on MergeLimitedSink, which depends on CurrentThreadScheduler. |
There was a problem hiding this comment.
@freak4pc This PR is in DRAFT for now. It adds wasm compilation to RxSwift. I had to make a few changes that I would consider a hack, especially this. This isn't a terrible hack since it is isolated to wasm only, and since wasm is currently pretty much single-threaded.
But I wanted to call this out.
If you're interested in merging this with this wasm-only hack in place, then I'm happy to move this PR out of draft. But I'm not sure I'll have resources to fully implement a full solution for CurrentThreadScheduler, since our company went a different way other than RxSwift.
|
Closing this PR as there doesn't seem to be interest. Happy to re-open if someone wants these changes. Please @ mention me in a comment if the need comes up. |
Change summary
DRAFT ONLY
Adds support for compiling RxSwift to wasm using the Swift for WebAssembly SDK.
Change details
swift-atomicsandswift-dispatch-asyncdependencies for WASM builds onlyOutstanding tasks
The following tasks need completed for this PR to exit draft phase.
Testing Done
Tested compiling and running this as part of a large web app.
Note that this PR is part of a larger effort by PassiveLogic to improve Swift for WebAssembly support.