Q: SVG.JS element ordering Maybe someone can help me here. Probably is a stupid question...but I try
I want to load svg.js elements from file and restore their drawing order.
I can save the order on file and load it and store in a variable but then it reach maximum call stack when I use the following function:
//Order loaded element
    function ordering(el,order){
        console.log('ordering '+ el.position(), order)
        if(el.position() > order){
            el.backward();
            ordering(el,order);
        } else if(el.position() < order){
            el.forward();
            ordering(el,order);
        } else {
            return;
        }

    }

any suggestion? THX by the way
