All Questions
Tagged with typescript rxjs
5,414
questions
0
votes
3
answers
28
views
Property 'results' does not exist on type 'HttpEvent<MovieResponse>'. TypeScript Error
I'm currently using this TMDB endpoint in my Angular 18 application and setting it to a variable.
This is how it looks:
private trendingMovies$ = this.http.get<MovieResponse>(${this.apiUrl}...
1
vote
3
answers
37
views
Rxjs: infinite loop with value in each call is the result from the previous
Says, I have an api call that take an input since which is Unix timestamp.
fetchData = (since?) => {
const now = Math.floor(Date.now() / 1000); // Current Unix timestamp in seconds
if (...
2
votes
1
answer
28
views
How to use the retry from Rxjs to my await function?
I have to return an await function from my code block, now when the await function is called and failed on the first try, I want to retry it again and if it failed on the second time.. I will show an ...
1
vote
2
answers
38
views
Replacing a nested subscribe when getting multiple details from one initial call for ids
So I'm making a few calls to two back-end services, the first is to get the IDs of "big" items and the rest are separate calls to get the details of each "big" item using its ID.
I'...
2
votes
2
answers
64
views
RXJS - Using concatMap dynamically
I am attempting to do in order async manipulation of strings in an array. The class has an array of objects that have a transform method that return an observable. Each transform call depends on the ...
0
votes
0
answers
48
views
Typing an RxJS pipeline
How do you define an OperatorPipeline<I, O> type (essentially the arguments you pass to Observable.pipe()) that takes zero or more RxJS operators and matches:
the pipeline input with the input ...
1
vote
1
answer
44
views
Promise not returning the real response
I have a page that contains tabs. When I click on a specific tab the component related to it is created. It goes in the ngOnInit and when I leave the tab onDestroy is called.
In my ngOnInit function I ...
1
vote
1
answer
41
views
RxJS alternative to debounceTime operator, so items won't get collected?
RxJS pros out there, I need your help!
Based on my last question I'm now looking for something different:
Question: How to separate values of a stream, keep the last of each and force flush after a ...
3
votes
2
answers
117
views
RxJS observable that fires if it's the first of a kind OR a certain time went by
Hey RxJS pros out there,
I have a stream that procs multiple times a second. Now I want an observer that procs if it's the first of a kind OR a certain time went by after the last proc. I want to ...
1
vote
1
answer
34
views
How to Skip the First Value of Stream Except if It is a Copy Paste With RxJS?
I am currently using skip(1) to avoid unnecessary calculations when the first value is typed. However, I discovered that my users frequently use copy-paste to filter data. As a result, skip(1) skips ...
1
vote
1
answer
142
views
Angular 18 - RxJS : Subscribe is deprecated [duplicate]
Subscribe will be deprecated. The example I have seen on the RxJS website don't really use any observers. If I remove subscribe from the following code, I get "error TS2349: This expression is ...
0
votes
0
answers
26
views
How I can handle TS types error MQTT.js with RxJs
I have a problem in attempt to use rxjs with mqtt.js
import { connect, IClientOptions, IPublishPacket, Packet } from "mqtt";
import { fromEvent } from "rxjs";
import { bufferTime, ...
1
vote
1
answer
50
views
Send data to different component with angular emit
There is a button that calculates desi on the product editing page. When this button is clicked, a different component, the modal, opens. In the opened modal, desi calculation is made by taking the ...
-1
votes
1
answer
37
views
How to Group by user, type and sum a few properties in angular using rxjs
I want to group the user by type(contractor or staff) and sum the Unit(words / hrs) and Cost.
I have tried the following code but no luck.
this.jobsGroupBy = of(this.jobDetails).pipe(
...
0
votes
1
answer
187
views
Angular HttpClient calls and signals
I am diving deep into signals watching tutorials and reading articles. When calling an api endpoint with httpClient I've seen two main approaches (at least that I liked) and I am unable to find much ...