ocean O
asked on
httpClient doesn't exist in angular
Hi, I have a question regarding angular httpClient.
I have some code below, it throws an error for me:
Property 'httpClient' does not exist on type 'DocService'.ts
createObservable(JsonUrl): Observable<any[]> {
return this.httpClient.get<any[]>(this.baseBatchURL + "getResults", {
params: JsonUrl,
});
}
getValidationData(): Observable<any> {
return this.createObservable(JsonUrl);
}
JsonUrl is passing a json file.
Any inputs are welcome.Thanks
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Glad to help!!
ASKER
Thank you.