I
I
ihabia2019-08-26 19:47:35
stylus
ihabia, 2019-08-26 19:47:35

Can stylus variables be used in paths?

Who uses this preprocessor, tell me, does it have the ability to substitute the values ​​of variables in the path?
For example I have a src path: url('../fonts/SourceSansPro/SourceSansPro-BlackItalic.eot');
I want to use /fonts/ /SourceSansPro-BlackItalic.eot variable
instead of /SourceSansPro/ Is this possible?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
O
Oleg, 2019-08-26
@ihabia

src: url('../fonts/' + fontName + '/SourceSansPro-BlackItalic.eot');

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question