2

What's the Combine's equivalent to concatMap? I want to keep the order of downstream items to be the same as the original upstream items

[1,2,3].publisher.flatMap { self.getItem($0) } // This does not guarantee [Item1, Item2, Item3]
Jack Guo
  • 3,959
  • 8
  • 39
  • 60
  • I may be missing something, but why aren't you using `compactMap`? I'm pretty sure `flatMap` was deprecated. – Daniel Jun 27 '20 at 23:39
  • [According to this cheatsheet](https://github.com/CombineCommunity/rxswift-to-combine-cheatsheet), there is no equivalent. You'd need to build it yourself. – Sweeper Jun 28 '20 at 00:09

0 Answers0