Angular: select with empty initial option

http://angularjs.org/

by mrajcok

HTML

<div ng-controller="MyCtrl">
  <select ng-model="selected_year" ng-options="year for year in years"></select>
    {{selected_year}}
</div>

JavaScript

function MyCtrl($scope) {
    $scope.years = [1990, 1991, 1992];
    // Don't set $scope.selected_year if you want a blank
    // item to appear in the list initially
    //$scope.selected_year = 1991;
}