Using AngularJS, how do you create a subset of items in an array?
For example; create a new array from "todos" that only includes the "done:true" items.
function fooController ($scope) {
$scope.todos = [
{text:'foo' , done:false},
{text:'foobar' , done:true},
{text:'foofoo' , done:false},
{text:'foobar2' , done:true}
]
}
http://docs.angularjs.org/api/ng.filter:filter
See about 10:45 -> end