In my HTML code, I have three divs each with unique content.
There is a sequence object that dynamically changes the order in which the divs are displayed.
The sequence object looks like this: { "div1": 1, "div2": 3, "div3": 2 }
To arrange the divs according to the sequence object, I attempted using ng-if by creating 9 divs.
<div ng-if="sequence.div1=1"></div>
<div ng-if="sequence.div2=1"></div>
<div ng-if="sequence.div3=1"></div>
<div ng-if="sequence.div1=2"></div>
<div ng-if="sequence.div2=2"></div>
<div ng-if="sequence.div3=2"></div>
<div ng-if="sequence.div1=3"></div>
<div ng-if="sequence.div2=3"></div>
<div ng-if="sequence.div3=3"></div>
I'm wondering if there is a more efficient way to achieve this layout without having to use 9 individual divs.