I am trying to animate a loaded SVG in a circular motion. Here is the code I have so far, where my goal is to rotate the object in a circle with a radius of 30:
var svgObject = Snap("svg#object g");
var path = svgObject.path("M0 0 a60 60 0 0 0 30 30");
var pathLength = path.getTotalLength();
Snap.animate(0, pathLength, function(value) {
movePoint = path.getPointAtLength(value);
svgObject.transform('t' + parseInt(movePoint.x) + ',' + parseInt(movePoint.y));
}, 5000, mina.easeOut);
I understand that the current code only moves the object to the right and does not complete a full circle. My desired outcome is for the object to return to its original position after completing a circle.
What changes should be made to the existing code in order to achieve this?