Filter for change Date format (MM-dd-yyyy) in Angular Js

date formats
angular js

By using below filter for change Date format (MM-dd-yyyy) in Angular Js, for given date.
Ex : 2017-03-05 08:40:00. By using the below filter the final result is 03-05-2017

filter('ChangeDateFormat', function($filter)
	return function(input)
		if(input == null){ return ""; }
		var _date = $filter('date')(new Date(input), 'MM-dd-yyyy');
		return _date;



You might also like:

Compare the Triplets | Javascript |


How to search text in string using php ?

29-10-2017 php search string search

Filter for replace text in Angular Js

05-03-2017 filter replace angular js

Sample Validations in javascript

22-02-2017 validations javascript

Email validation regular expression in javascript

22-02-2017 email validation regex