Question

I noticed that in the gumby.scss file, there is the line:

@import "custom";

... but the filename itself is _custom.scss.

For every file that I create after that, do I include the underscore?

As an example, if I create a file _custom2.scss, would I then use the import

@import "custom2";

or

@import "_custom2":

?

If it assumes that there will be an underscore in the file name, what are the rules for its assumptions? Does it do that with all filenames?

Was it helpful?

Solution

You can use either.

A file that begins with an _ is a partial in Sass.

Basically, if you want it to generate its own css file, don't add the underscore. If you want to import it into another sass file, use the _.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top