V
V
Vadim Sverdlik2020-07-02 12:26:46
css
Vadim Sverdlik, 2020-07-02 12:26:46

How to set styles via css in svg stroke element?

I have stroke="black" in path and I can't manipulate it with css. How to register this element in styles and manipulate it?

<svg width="9" height="6" viewBox="0 0 9 6" fill="none" xmlns="http://www.w3.org/2000/svg">
<path opacity="0.3" d="M0.954102 0.826172L4.65962 4.53175L8.36519 0.826172" stroke="black"/>
</svg>

Answer the question

In order to leave comments, you need to log in

2 answer(s)
E
Eugene Chefranov, 2020-07-02
@Chefranov

svg path {stroke: #CCC;}
and remove the inline color, otherwise it will interrupt

S
Stalker_RED, 2020-07-02
@Stalker_RED

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question