R
R
rinatoptimus2016-12-08 17:05:45
Sass
rinatoptimus, 2016-12-08 17:05:45

How to prevent SASS file import from repeating?

There is a file "_variables" which is imported into "_header", "_content", "_footer". And there is a "style.scss" file, in which these "_header", "_content", "_footer" are connected. As a result, the code of the "_variables" file is copied several times in the "style.css" file. How to set up the import correctly?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
I
Igor Voronov, 2016-12-08
@rinatoptimus

Is importing only in style.scss not an option?
Import everything into one shared file. You can use all the variables declared in _variables in all other files that are included in style.scss (I guess that was the problem).

A
Andrey Khokhlov, 2016-12-08
@andrhohlov

Import everything 1 time and only in the file that eventually compiles (style.scss)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question