1
更新NG風格我有一個ng-style
內的ng-repeat
。問題是ng-style
值在更改後更新,但實際樣式不會更改。如何NG重複
<tr class="row" ng-repeat="(hourIndex, hour) in day track by $index">
<td class="cell"
ng-style="{ 'background-color': '{{ switchBackgroundColor(hour) }}' }">
{{ hour }}%
</td>
</tr>
如上一次的日子,進而小時的變化說明,ng-style
被更新。此更新未反映在該樣式中。