I use ng-select to populate my options, but I want to pass the selected index, what should be in the ng-change function?
like if the user selected b I will get 1 which is the second index of the array.
<select
ng-options="p as a for a in alpa"
ng-model="selected" ng-change="detectChange('what to pass index here?')"></select>