Does anybody know how I can SKIP JSON ordering altogether when I use ng-repeat (in a painless way probably)?
For example, my source JSON looks somet
I am using this approach to override the alphabetical ordering:
Controller:
$scope.steps = {
"basic-settings": "Basic Settings",
"editor": "Editor",
"preview-and-publish": "Preview & Publish"
};
// NOTE I realise this is a hacky way, but I need to override JS's alphabetical ordering
$scope.stepsKeys = _.keys($scope.steps);
$scope.activeStep = 0;
PLEASE NOTE that _.keys($scope.steps); is LoDash substituting Object.keys();
HTML:
- {{ steps[key] }}