ng-table
ng-table copied to clipboard
one-time data binding on $data
Hi there, thanks for your great module. Is there any way to use one-time binding on the $data array in ng-repeat? Using this on the row works fine. But if add :: to $data no row will be rendered.
<table ng-table="::listParams.articles" class="table table-striped">
<tr ng-repeat="article in ::$data track by article.id">
<td data-title="'articleNumber'" sortable="'no'" ng-bind="::article.no"></td>
<td data-title="'articleDesc'" sortable="'name'" ng-bind="::article.name"></td>
</tr>
</table>
Hello,
did you find a solution for this? From my point of view, the problem is that "data" is initialized as "[]" and therfor is stabilized when one-time binding takes place. I am new to AngularJS and cannot think about a good work around.
Since, Angular 1 is a little out of date by now, I didn't investigate any further. Just used two-way binding.
Touché! Sadly I came into a project that is still using Angular 1 :D But thanks for your quick response, have a good day.