All Questions
5
questions
0
votes
2
answers
1k
views
Deleting stored observable value in angular service
I have a observable service:
GetInputValueObservableService:
private inputObservable = new BehaviourSubject<string>(null);
setObservable(text) {
this.inputObservable.next(text);
}
...
0
votes
1
answer
36
views
Running code regardless of observables existing, but waiting for them if they do?
I have the following code:
array1.foreach(a => {
if (a === whatever) {
function1.subscribe();
}
});
array2.foreach(b => {
if (b === whatever) {
...
1
vote
1
answer
949
views
Observable/BehaviorSubject not working in different modules of Angular
I have 1 feature module (Fund module) that displays fund data in one of its components and an AppModule that displays Advisor data. Fund data and Advisor data have one to many relationship.
Fund ...
1
vote
0
answers
706
views
RxJS switchMap operator does not cancel http request
I have been struggling to figure out why the HTTP requests are not been canceled using the switchMap operator.
import {Observable, of, Subject, Subscription, timer} from 'rxjs';
import {HttpClient} ...
0
votes
0
answers
318
views
Angular 10: subscribing to an observable won't fire after a next call
I have a very simple scenario of subscribing to an Observable via an injected FooService:
foo.service.ts:
@Injectable()
export class FooService {
private foosSubject = new Subject<...