Skip to content

Instantly share code, notes, and snippets.

@Insayt
Created September 18, 2015 21:56
Show Gist options
  • Save Insayt/966e8f63f86711bbc7ad to your computer and use it in GitHub Desktop.
Save Insayt/966e8f63f86711bbc7ad to your computer and use it in GitHub Desktop.
app.directive('select', function() {
return {
link: function($scope, element, attrs, $rootScope) {
setTimeout(function() {
$(element).on( 'change.fs', function(e) {
$(element).val(e.target.value).trigger('input');
$scope.$emit('filter:change');
} ).fancySelect();
}, 0);
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment