0
I have an input (multiple selection), I am using lib ui-select, I get a city list and need to filter them, the problem is that the Angularjs filter filters the whole word, I need to filter the beginning of the word.
Example of search : river.
Result: Balneariver Staggered.
Expected Result: River january.
<ui-select
on-select="onSelectCity($item)"
on-remove="onRemoveCity($item)"
limit="3"
input-id="cities"
multiple
ng-model="multipleCities"
theme="bootstrap"
close-on-select="true"
title="Escolha uma cidade">
<ui-select-match placeholder="Digite o(s) município(s) que deseja filtrar (máx. 03)">{{$item.city}}/{{$item.uf}}</ui-select-match>
<ui-select-choices repeat="city in avaiableCities | filter:$select.search track by $index">{{city.city}}/{{city.uf}}</ui-select-choices></ui-select>