This is the Http Call I am working with:
fetchData(): Observable<MyTypedData> {
return this.httpClient.post<MyTypedData>(this._url, httpOptions)
.pipe(
catchError(this.handleErrors)
);
}
The structure of MyTypedData.ts is as follows:
export class MyTypedData {
id: number;
name: string;
}
Here is a JSON Response (Incomplete MyTypedData):
{ "id": 123, "status": "active" }
I intentionally created this incomplete JSON response to test something.
Question: Will there be an error thrown by HttpClient due to the incomplete data in the response and trigger the error function for subscribers?