Read JSON object from Url in AngularJS 2

Last Reply one year ago By dharmendr

Posted one year ago

Hi sir,

i am refering  this link

to read the array of json object,

like  that i  created  method ..

export class EmployeeService {
private _url: string = 'http://localhost:8080/Employee/getEmployeeList';

constructor(private _http: Http) {

public getallemployee() {
return this._http.get(this._url)
.map((response: Response ) => response.json());

but i am not able to read the json data, so what can i place in the _url,

my method getEmployeeList return array of json object,

thanks and regards