angular http call code example
Example: use of http in angular 8
Add in -> app/app.module.ts
import { HttpClientModule } from '@angular/common/http';
imports: [
// import HttpClientModule after BrowserModule.
HttpClientModule,
],
Add in service
import { HttpClient } from '@angular/common/http';
constructor(private http: HttpClient) { }
Make get request
return this.http.get(this.configUrl);