I have a ng-repeat with input box in each repeated item. I have set the autofocus to input.
<input type="text" autofocus />
So autofocus will be applied to all items. However, there's a bug in iOS where the last input box is auto focused instead of the first one.
I need to set it to return true based on the condition as in:
<input autofocus="{{$first ? 'true' : 'false' }}" >
Any idea how to accomplish this with Angular?