1

I have following imports in my "themes.scss" files

@import "components/modal";
@import "components/button";
@import "components/grid";
@import "components/calendar";
@import "components/popover";
@import "components/tab";
@import "components/icon";

I have tried following way to import all the ".scss" files at one time:

@import "components/*"

Unfortunately it's not working (in windows 8), I am getting an error while scss to css compilation.

Syntax error: It's not clear which file to import for '@import "components/*"'.
              Candidates:
                components/_modal.scss
                components/_button.scss
                components/_grid.scss
                components/_calendar.scss
                .
                .
              Please delete or rename all but one of these files.
        on line 8 of C:\component\theme.scss
  Use --trace for backtrace.

Is there any way through which I can convert all the scss files by just importing parent folder instead of each individual scss file?

Appreciate your help.

SatAj
  • 1,899
  • 4
  • 29
  • 47
  • @cimmanon Answer provided in the previously asked question wasn't working.. (Is it possible to import a whole directory in sass using @import? ) – SatAj Jan 08 '16 at 23:56
  • Which answer doesn't work? – cimmanon Jan 09 '16 at 00:23
  • I tried both ways by referring the originally answered question, none of them worked: i) @import "foo/*" // import all the files in the foo folder ii)@import "bar/**/*" // import all the files in the bar tree – SatAj Jan 12 '16 at 21:32
  • 1
    Did you skip over the fact that it only works if you're using Ruby-on-Rails or if you're using the sass-globbing extension? – cimmanon Jan 12 '16 at 21:35
  • I am looking for a generic solution without that condition (already checked the question you've mentioned before posting this). So far didn't found any solution, so thought of posting the question on SO. – SatAj Jan 12 '16 at 21:44

0 Answers0