Skip to content

Instantly share code, notes, and snippets.

@etaque
Created December 18, 2013 13:47
Show Gist options
  • Save etaque/8022634 to your computer and use it in GitHub Desktop.
Save etaque/8022634 to your computer and use it in GitHub Desktop.
loop with lesscss
.rotate (@deg) {
-webkit-transform: rotate(@deg);
-moz-transform: rotate(@deg);
-ms-transform: rotate(@deg);
-o-transform: rotate(@deg);
}
.loopRotated(@index) when (@index > 0) {
.rotated-@{index} {
.rotate(@index * 1deg);
}
.loopRotated(@index - 1);
}
.loopRotated(0) {}
.loopRotated(360);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment