Angular Select Filter w/ ng-if
Filtering the OPTIONs of a SELECT using the Angular ng-if directive.
by Alexander
HTML
<script src="https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.1.5/angular.min.js"></script>
<div ng-app ng-controller="Controller">
<select ng-model="myDropDown">
<option value="one">One</option>
<option value="two" ng-if="myDropDown=='one'">Two</option>
<option value="three">Three</option>
</select>
{{myDropDown}}
</div>
JavaScript
function Controller ($scope) {
$scope.myDropDown = 'three';
}