Answer the question
In order to leave comments, you need to log in
Is it possible to animate svg in pure javascript?
Is it possible to animate svg with pure javascript? Or do you need special libraries such as D3.js?
Answer the question
In order to leave comments, you need to log in
d3.js is written in pure javascript, so yes. can. The issue is labor costs. From experience, I’ll say that it’s easier to take d3.js where many simplifiers are implemented.
If you are interested in the question of how, first you should understand how SVGs are animated in general. And then figure out how to do it in JS. Well, or look at the source code of d3.js itself.
https://css-tricks.com/guide-svg-animations-smil/
There is a small library to animate svg https://github.com/maxwellito/vivus
Dude, just out of curiosity, how did you google if you couldn't find anything?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question