One of my functions takes a DTO object and converts it into an observable that emits the transformed Entity. Here is the function signature:
dtoTransformer(dto: DTO): Observable<Entity>
I also have another function that returns an Observable containing a list of DTOs:
getDTOs(): Observable<DTO[]>
Using these two functions, I am trying to write a new function that will return an observable containing a list of Entities, transformed from the received DTOs:
getEntities(): Observable<Entity[]>
The challenge I am facing is applying the dtoTransformer function to each value in the DTO list within the observable. Is there an operator that can assist me with this? I could use some guidance on how to approach this.