Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Convert cents to dollars.
angular.module('MyModule')
.filter('dollars', function() {
return function(input) {
return '$' + parseInt(input, 10) / 100;
};
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment