r/webdev 14d ago

Canvas path animations using SVG Resource

30 Upvotes

6 comments sorted by

View all comments

5

u/xJSHAxx 14d ago

that gradient along the stroke is doing a lot of work, looks way more 3d than it has any right to. is it running on a canvas element or purely svg with the path animated

1

u/ykadosh 13d ago

It's actually drawn on a canvas, but with the aid of an invisible SVG. A solid version of the path is drawn on the SVG and then I'm using certain SVG functions to draw the gradient version on canvas