files/en-us/web/svg/reference/attribute/vector-effect/index.md
The vector-effect property specifies the vector effect to use when drawing an object. Vector effects are applied before any of the other compositing operations, i.e., filters, masks and clips.
[!NOTE] As a presentation attribute,
vector-effectalso has a CSS property counterpart: {{cssxref("vector-effect")}}. When both are specified, the CSS property takes priority.
You can use this attribute with the following SVG elements:
none
non-scaling-stroke
[!NOTE] The spec defines three other values,
non-scaling-size,non-rotation, andfixed-position, but these have no implementations and are considered at-risk.
vector-effect as non-scaling-stroke<svg viewBox="0 0 500 240">
<!-- normal -->
<path
d="M10,20 L40,100 L39,200 z"
stroke="black"
stroke-width="2px"
fill="none"></path>
<!-- scaled -->
<path
transform="translate(100,0) scale(4,1)"
d="M10,20 L40,100 L39,200 z"
stroke="black"
stroke-width="2px"
fill="none"></path>
<!-- fixed-->
<path
vector-effect="non-scaling-stroke"
transform="translate(300, 0) scale(4, 1)"
d="M10,20 L40,100 L39,200 z"
stroke="black"
stroke-width="2px"
fill="none"></path>
</svg>
{{EmbedLiveSample("Setting vector-effect as non-scaling-stroke", 550, 330)}}
{{Specifications}}
{{Compat}}