Last active
April 26, 2017 00:00
-
-
Save nickcherry/27f0862beefacbcdc4c2 to your computer and use it in GitHub Desktop.
custom-angular-select (array of strings)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
angular.module 'angular-custom-select-examples', ['angular-custom-select'] | |
.controller 'ExamplesController', ($scope) -> | |
$scope.selectedValues = {} | |
$scope.strings = ['Option A', 'Option B', 'Option C', 'Option D', 'Option E'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
custom-select | |
ng-model="selectedValues.string" | |
ng-options="string for string in strings" | |
placeholder="Select one of these string values..."> | |
</custom-select> | |
<div class="selected-value"> | |
Selected Value: {{ selectedValues.string || 'N/A' }} | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment