I can mock up a full repro if needed, but the basic steps are easy enough. Just make a view with <path class="test" />. It will compile as expected, but at runtime you'll get this:
Uncaught TypeError: Cannot assign to read only property 'className' of object '#<SVGPathElement>'
Per the spec, SVGElement's className is a read only SVGAnimatedString instance, and also deprecated. Spec suggests using classList instead, but setAttribute('class', ... ) would probably work if you're looking to avoid classList for other reasons.
Likely affects all SVG elements.
I can mock up a full repro if needed, but the basic steps are easy enough. Just make a view with
<path class="test" />
. It will compile as expected, but at runtime you'll get this:Uncaught TypeError: Cannot assign to read only property 'className' of object '#<SVGPathElement>'
Per the spec,
SVGElement
'sclassName
is a read onlySVGAnimatedString
instance, and also deprecated. Spec suggests usingclassList
instead, butsetAttribute('class', ... )
would probably work if you're looking to avoidclassList
for other reasons.