1

I have an svg path whose width is 90vw and whose stroke-dasharray is 0 90vw to produce a dot that can be animated along a line. This works in Chrome, but Safari strokes the whole path. It does not appear to like the vw unit here, though it is fine with it in the stroke-dashoffset property, and I can't find any mention of this on the web. Is there something obvious I'm missing about how I've formatted the property?

path#dot {
  stroke-width: 32;
  stroke-linecap: round;
  stroke-dasharray: 0 90vw;
  stroke-dashoffset: 45vw;
}

Thanks

Matt
  • 11
  • 2

1 Answers1

0

AFAIK, support for the new CSS3 units, in an SVG context, is limited at the moment. Last I heard, only Chrome/Blink (so probably Opera as well) supports these units currently.

Paul LeBeau
  • 97,474
  • 9
  • 154
  • 181