Как мы можем использовать метод 'filter', чтобы упорядочить даты в возрастающем или убывающем порядке?
<html>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.9/angular.min.js">
</script>
<body>
<div ng-app="myApp" ng-controller="orderCtrl">
<ul><li ng-repeat="x in dates | orderBy">{{x}}</li></ul>
</div>
<script>
var app = angular.module('myApp', []);
app.controller('orderCtrl', function($scope) {
$scope.dates = ["01/02/2018", "02/02/2018", "06/06/2018", "01/22/2019", "12/12/2018"];
});
</script>
</body>
</html>
Получение выходных данных от 01.02.2008 г. 01.02.2017 02/02 /2018 06/06/2018 12/12/2018
Исключенный выходной 01/02/2018 02/02/2018 06/06/2018 12/12/2018 01/22/2019