I am playing around with a cool effect that I found on codepen here:
https://codepen.io/P3R0/pen/zxabvb
I want to make the dashes on this svg animation shorter, and believe I have found the css element which does this:
stroke-dasharray: 70 330;
When I reduce 70 to 30 for example, the dashes become shorter which is good. However you will notice they no longer glide around smoothly - they now jump position.
I've been searching and trying to understand how stoke-dasharray works, but can't work it out. Can anyone explain to me how these numbers work and how I can make shorter dashes which still glide around smoothly.
Thanks for any help.
The first parameter of the stroke-dasharray is the length of the filled area and the second one is the total length of the shape. You can fix your animation by shortening the total length as below.