Animation in React

I’ve been trying to make an animation work in React, with no success. Can someone please help. Here is the pomodoro clock I’m working on.

I want the pointer to move to the correct time as the time decreases. It works on the first load, but fails to animate after that. I’ve searched all over the net, tried various techniques, but nothing seems to work. My guess is that the component ‘Scale’ is not rerendering the animation.

This may not be helpful but instead of animateMotion try to use animate

Thank you for responding. I need to animate the pointer on a curved path. How can I do that with . I don’t see any attributes to provide the SVG path coordinates.

Sorry, I looked at it for a while. I’m just not familiar enough with SVG I couldn’t get it to work either.

Thanks for trying! I’m still searching for more options.

I made it work! I removed the animation and instead used the css style offsetDistance on the pointer.