I had a nice idea, but it doesnt work.
Because I have in the ion-nav-bar a Button for the search, i would replace the header with a search input if the user would search.
So I developed it with a simple input and ng-model=“search”.
In the ion-content I use ng-repeat with a filter.
It looks like…
…and…
.
And that’s the script behind.
<ion-nav-title>
<span ng-hide="search">Title</span>
<span ng-if="search">
<label class="item item-input">
<input type="text" placeholder="Search..." ng-model="searchText">
</label>
</span>
</ion-nav-title>
With the ng-repeat
<ion-content>
<div class="categories-list">
<div ng-repeat="item in items | filter: searchText">{{ item }}</div>
</div>
</ion-content>
But if i enter something the filter would’nt applied.
Whats wrong?
Thanks in Advance!