Hey guys. Did anyone try to create the nested accordion list in Ionic, please? I need maybe 3 or 4 levels, not just one like in the demo.
Have you found a solution? I’m also wanting to create this, but for just 2 levels.
change original controller.js
$scope.shownGroup = [];
/ACCORDION/
$scope.toggleGroup = function (group) {
if ($scope.isGroupShown(group)) {
$scope.shownGroup.splice($scope.shownGroup.indexOf(group), 1);
} else {
$scope.shownGroup.push(group);
}
};
$scope.isGroupShown = function (group) {
return $scope.shownGroup.indexOf(group) > -1;
};
Hi!
I’ve found this example but it stops at 3rd level (leaf nodes only). I think adding more level (e.g. up to 5) can be too much tricky. What do you think?