Whenever any ongoing transformation is complete (or when the element is first rendered) the transform property, which is responsible for any movement/animation, is getting set to rotate(360deg), which then takes this element and rotates it full circle.
4
u/[deleted] May 02 '19 edited May 02 '19
Here's the same thing without any JavaScript at all, just CSS:
https://jsfiddle.net/k1rzxumv/
Oh and the planets rotate too. =)