Skip to content

Instantly share code, notes, and snippets.

@sanusart
Last active October 29, 2017 04:36
Show Gist options
  • Save sanusart/9031706 to your computer and use it in GitHub Desktop.
Save sanusart/9031706 to your computer and use it in GitHub Desktop.
AngularJS join by character #AngularJS #javascript #angular1
angular.module('App.filters', [])
.filter('joinBy', function () {
return function (input,delimiter) {
return (input || []).join(delimiter || ',');
};
});
{{ itemsArray | joinBy:',' }}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment