Skip to main content

All Questions

Tagged with
1 vote
1 answer
67 views

It is valid Accessing BehaviorRelay value directly for UITableView in RxSwift?

I'm working with RxSwift and have a scenario where I use a BehaviorRelay in my ViewModel to hold an array of data for a UITableView. I've set up a subscription to this BehaviorRelay specifically to ...
Popala Kyu's user avatar
1 vote
1 answer
830 views

Observe an RxSwift.BehaviorRelay just **before** a change happens

In RxSwift, how can I observe a BehaviorRelay just before a change happens? I tried: object.subscribe(onNext: {...}) with which I get a notification only after the new value has been set.
quinn45's user avatar
  • 13
0 votes
0 answers
361 views

Not Sure If I am using Rx Swift Correctly - BehaviorRelay Bind to TableView

I am trying to update tableview via a delete button on my table cell class. But it doesn't update the tableview instantly which I don't know if it's too much to ask from behavior relay. Properties: ...
iPancake's user avatar
  • 109
2 votes
1 answer
451 views

How to make a proper reactive extension on Eureka SelectableSection

This is my first question to the StackOverflow community so excuse me if I'm doing something wrong. 1. What I'm trying to achieve Basically, I want to make a custom reactive wrapper around Eureka's ...
Radu's user avatar
  • 23
1 vote
2 answers
368 views

Does Swift's Combine framework have a sample(on:) operator similar to those in RXSwift or Reactive Swift?

Does anyone know how to recreate sampling behavior in Combine? Here's a diagram of the sample's behavior in RXMarbles The gist of sample() is that there are two streams, when one is triggered, the ...
Yogurt's user avatar
  • 3,015
4 votes
3 answers
3k views

RxSwift Use withLatestFrom operator with multiple sources

I have 3 observables, namely source, source1 and source2. What I want is whenever source emits a distinct event to get the value of source1 and source2. This is the code I've come up with, obviously ...
Daniyal Raza's user avatar
2 votes
1 answer
1k views

RxSwift - change specific object in PublishSubject on event

struct Contact : Codable, Hashable { var id : String ... } I use PublishSubject to feed the data to the UITableView let contacts : PublishSubject<[Contact]> = PublishSubject() And when ...
Jun's user avatar
  • 3,432
1 vote
1 answer
467 views

How to implement Recursive Paginated Network Call using RxSwift

I have an endpoint that returns the items of the current page. Also, if you want to get next page's items, you have to construct a URL with the next page's hash. This hash returns as property in the ...
erica.lecta1's user avatar
2 votes
1 answer
1k views

error: Segmentation fault: 11 (in target 'RxSwift' from project 'RxSwift')

I have just created my first project in RxSwift. The sample project named is RxSwift and added below pods in Podfile following the guidelines here. Podfile: # Podfile use_frameworks! target 'RxSwift' ...
Sazzad Hissain Khan's user avatar
1 vote
1 answer
121 views

Reactive asynchronous feedback system with RxSwift

I am designing a call manager with the help of RXSwift (ReactiveX) that continuously interacts with an API. The call manager comprises several objects that itself comprises an indicator (indicating ...
Maschina's user avatar
  • 886
-2 votes
2 answers
451 views

What is the difference between Do and Map?

What is the difference between do operator and map operator? It seems the same. I'm learning RxSwift. Please check the marble diagram of do and map. do : http://reactivex.io/documentation/operators/...
YOSUKE's user avatar
  • 341
1 vote
1 answer
1k views

Operator with two last elements from Observable in RxSwift

I have an observable sequence of Ints: -1-2-3-4-5-6-3-4-5-1- For example, I need to detect when the previous element was bigger than the last one. In this sequence it's (6, 3) and (5, 1): -1-2-3-4-...
Evgeny's user avatar
  • 641
0 votes
1 answer
638 views

How to pass data from delegate method to the observable's onNext method in RxSwift?

I have manager class which will connect and manage the data and state of the Bluetooth device. The manager class conforms to IWDeviceManagerDelegate and has a method which gives the weight data func ...
Anirudha Mahale's user avatar
1 vote
1 answer
263 views

Is it bad idea to create static stream in reactive programming?

Now I'm working on iOS using RxSwift framework. In my app I have to user user location, but I don't need it to be updated in real time. It's enough if location updated every time user opens app or ...
えるまる's user avatar
  • 2,493
4 votes
1 answer
692 views

What is the difference between merge and flatmap operator in RxSwift

I am currently new to RxSwift and I am a little bit confused about the flatMap and merge operator. I know the merge operator merges more than one observable into a single observable. I feel that ...
Ahmed's user avatar
  • 1,299

15 30 50 per page