how to rotate circles in web? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

how to rotate circles in web?

im developing a game in which a circle rotates. im guessing this is easy, does anyone know how to turn a circle in html/css/js? it is going to be a js function that rotates the circle, i cant figure out what to have the function modify.

11th Jul 2018, 10:49 PM
privrax.
privrax. - avatar
3 Answers
+ 1
You can use CSS3's animation feature for this: .circle {animation-name: rotate; animation-duration: 3s; } @keyframes rotate { 0% {transform:rotate(0deg);} 100%{transform:rotate(360deg);} }
11th Jul 2018, 11:29 PM
Theresa
Theresa - avatar
12th Jul 2018, 12:28 AM
Calviղ
Calviղ - avatar
+ 1
https://code.sololearn.com/WxZ3iAmCM8It/?ref=app
12th Jul 2018, 1:09 AM
Calviղ
Calviղ - avatar