Help needed! I can't find Observable, how do I use rxjs on http? Can someone please provide guidance?
import { Injectable } from '@angular/core';
import { HttpClient } from '@angular/common/http';
import { IEmployee } from './employee';
import { Observable } from 'rxjs/Observable ';
@Injectable()
export class EmployeeService {
private _url: string = "/assests/data/employee.json";
constructor(private http: HttpClient) { }
getEmployees(): Observable<IEmployee[]>{
return this.http.get<IEmployee[]>(this._url);
}
}