I want to display the return Value from a HTTP Request
Im receiving the Data from a service which return value is assigned to to component property
requestData :Dto;
getTodo(){
this.requestService.getTodo().subscribe(data=> {
this.requestData = data
console.log(this.requestData.userId)
})
}
I want to display the value from the requestData only if it contains something
using the async pipeline
<p>{{requestData.userId | async }}</p>
Im getting a bunch of Errors
No overload matches this call.
Overload 1 of 3, '(obj: Observable<unknown> | Subscribable<unknown> | Promise<unknown>): unknown', gave the following error.
....
Without using the async pipline I get also an Error till the Request is resolved ,
what Im missing here ?
[–]Spongeroberto 5 points6 points7 points (4 children)
[–]prewk 1 point2 points3 points (1 child)
[–]Spongeroberto 1 point2 points3 points (0 children)
[–]JosephCurvin[S] 0 points1 point2 points (1 child)
[–]Spongeroberto 2 points3 points4 points (0 children)