Check out this straightforward directive to set autofocus:
app.directive('autoFocus', function($timeout) {
return {
restrict: 'AC',
link: function(_scope, _element) {
$timeout(function(){
_element[0].focus();
}, 0);
}
};
});
See it in action here: http://jsfiddle.net/ounsqcmt/55/
This directive may function perfectly in Chrome, but encounters issues in Firefox (version 36.00). Any suggestions?