A
A
Anton Anton2019-09-09 14:46:34
SVG
Anton Anton, 2019-09-09 14:46:34

How to scale SVG without changing stroke thickness?

I want to make a universal placeholder using svg.
So far I have done this: https://jsfiddle.net/kb8Lvw6u/1/
The problem is that the line thickness jumps. Is it possible to somehow scale the svg while maintaining line thickness without scale? Using js it is clear how to do it, but I want to do it without it.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anton Anton, 2019-09-09
@Fragster

It turns out there is a special crutch for this: https://developer.mozilla.org/en-US/docs/Web/SVG/A... .
More or less works: https://jsfiddle.net/8L6tuck5/2/ .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question