JSFiddle - React, Tailwind, and code Playground
by Alejandro M
HTML
<div ng-app="myList">
<div ng-controller="filteredList">
<ul ng-repeat="brand in brands">
<h1>
{{brand.name}}
</h1>
<li ng-repeat="product in brand.products | orderBy: model: true" ng-if="product.price >= 1100">{{product.model}} ({{product.year | date: 'yyyy'}}) - {{product.price | currency}}</li>
</ul>
</div>
</div>
JavaScript
var app = angular.module("myList", []);
app.controller("filteredList", ["$scope", function($scope) {
$scope.brands = [{
name: "Renault",
products: [{
model: "Megane",
price: 20000,
year: new Date("2015")
}, {
model: "Sandero",
price: 1200,
year: new Date("2003")
}]
}, {
name: "Ford",
products: [{
model: "F-150",
price: 10000,
year: new Date("2015")
}, {
model: "Sierra",
price: 1500,
year: new Date("1995")
}]
}];
}]);