benjamincharity
5/19/2015 - 1:20 PM

Convert cents to dollars.

Convert cents to dollars.

angular.module('MyModule')
.filter('dollars', function() {

  return function(input) {

    return '$' + parseInt(input, 10) / 100;

  };

});