Question: Is it possible to use the function placeBehind() with for example a new layer (foo = new Layer) and place it behind a layer generated from Sketch/Photoshop? It doesn't seem to work…
It works between new layers though.
To move a layer behind another layer, they need to have the same superLayer.
So you can do something like:
layerA = new Layer()
layerA.superLayer = sketchdocumentLayers.whatever.superLayerlayerA.placeBehind(sketchdocumentLayers.whatever)
Worked perfect, thanks :)