Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is '$data' in ngtable's HTML page

I am using ngtable and at this place in HTML while displaying table

<tr ng-repeat="row in $data">

I do not understand the use of $data, as '$' is not needed in other cases in ng-repeat.

like image 595
Himanshu Bhandari Avatar asked Apr 08 '15 06:04

Himanshu Bhandari


1 Answers

ng-table maintains it's own scope, and $data is the data which exists in this scope, rather than your full data set, which is on the scope of the page controller. It is the property that is populated by the getData() function call in the ngTableParams() object.

This usage and syntax is deprecated, and has been replaced entirely in the current ng-table source, which is now written in TypeScript as of v2.0.0.

like image 182
Claies Avatar answered Nov 10 '22 13:11

Claies