仍然不清楚如何显示或迭代对象对象。这是我的对象:
Row{
id: 1,
widget:{
name: 'bla bla',
location:{
top: 255, right: 0, bottom :0, left: 0;
}
}
location:{
top: 255, right: 0, bottom :0, left: 0;
}
}
这是 HTML
<div *ngFor="let row of canvas; let r = index" >
<div class="row" style="padding-top: row.location.top;">
ROW {{row}} {{ row.location | json}}
</div>
</div>
我想把row.location.top
我在对象中的样式内联。对于row.location | JSON
我得到的输出:
但如果我这样做,{{ row.location.top | json}}
我就会空虚。
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句