Answer the question
In order to leave comments, you need to log in
How to implement data return in angularjs?
How to implement a search field at the top of the page that filters the content of the active tab, showing only those list items that contain the text typed in the search field. If there are no such elements, the "Show all" link is shown, by clicking on which the search field is cleared and all elements of the corresponding list are shown. But the link-block list consists of several tabs,
for example, the first tab with books, after the tab associated with the authors of books, etc. .that is, binding data that is taken from the angular file.
I can't solve this problem
Answer the question
In order to leave comments, you need to log in
input type="text" ng-model="search.title"
.tab ng-click="activeTab='books'"
.tab ng-click="activeTab='authors'"
.tab ng-click="activeTab='etc'"
ul
li ng-repeat="item in data[activeTab] | filter:search"
| {{item.title}}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question