I have an idea on how to improve some code but that would require using arrays and these arrays have to have a certain sorting order.
I have a given array: var p = ['skewX', 'translateY', 'scale', 'rotateX'];
.
I need these strings sorted inside the array on a pattern:
0 translate
, 1 rotate
, 2 skew
, 3 scale
or
0 ordered translations
, 1 ordered rotations
, 2 ordered skews
, 3 ordered scales
where
index
and string
Question: is it possible to sort these arrays based on this pattern?
Thanks so much.