Modeling received messages as AsyncStream
#27
nikitamounier
started this conversation in
General
Replies: 1 comment
-
That PR is WIP, hence why it's missing API. I don't have the time to analyze this in depth right now, but it looks good from what I've seen in your example. This is definitely something that I want to have in the official API soon, since I'm also using Swift concurrency in my own projects. If you feel like opening a PR, perhaps picking up from the existing one, feel free to do so! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi Rambo,
First off, thank you for making this library – MPC is hard work, but this makes it so much easier. I'm trying to phase my code towards using Swift concurrency, and was wondering whether this is correct and doesn't disrespect any assumptions made in the library:
I saw that you have a draft PR for supporting Swift Concurrency, but I also saw that you hadn't made a "Swift Concurrency" version of
MultipeerTransceiver/receive(_:_:)
, so maybe there's something here that I'm missing.This would enable something like this, where here I'm juggling with both MultipeerKit and NearbyInteraction:
Which I find super clean!
Let me know what you think.
Beta Was this translation helpful? Give feedback.
All reactions