How would I recreate the following CSS code in Web Animation API

110 Views Asked by At

Looking at this site: https://css-tricks.com/svg-line-animation-works/

I found this https://i2.wp.com/css-tricks.com/wp-content/uploads/2014/02/animate-stroke-full.gif

I am now at a loss how to try to change the same property (stroke-dashoffset) using the web animation api WAAPI, anyone have any clue or where I should be searching for this information?

I cannot find out what keywords to use in my keyframes, or what is valid things to write in there even

1

There are 1 best solutions below

0
On

I missed the small but important print in the keyframe specification, change the property name from stroke-dashoffset to strokeDashoffset and it will work the same