我们如何从Angular 上的一组对象中获取数据.我已经提供了Typescript ;&服务文件;安慰的形象.我们如何才能获得图像中results对象内部的数据??
Ts文件
this.commonService.fetchVersionValue().subscribe((data) => {
console.warn(data);
});
服务文件
fetchVersionValue(): Observable<IVersionDetails[]> {
return this.http.get<IVersionDetails[]>(
`${this.PHP_API_SERVER}/api/get/versions`
);
}
形象
while looking the console I got the error
php服务器的Api帮助我解决了这个问题.提前感谢