As a beginner delving into Angular, I find myself working with a multiple select feature to filter a list by name.
<select multiple ng-options="data.name for data in datas" ng-model="filterData">
</select>
Currently, I am able to filter with only one value using the following:
<div class="container " data-ng-repeat="data in datas | filter : filterData[0].name">
However, my goal is to pass an array to the filter so I can filter by multiple values simultaneously.
Is creating my own custom filter the way to achieve this?
{
"datas": [
{"name": "first", "id": 1},
{"name": "two", "id": 2},
{"name": "three", "id": 3},
]
}
Thank you!