Dominik Spiertz
Dominik Spiertz

Reputation: 196

Compile partial SCSS-Files with Sass-Globbing in Jetbrains IDE

I just installed the sass-globbing-plugin to import partials recursively from a folder automatically.

Currently I am using the newest version of jetbrains pycharm. To activate sass-globbing to the existing scss-filewatcher, I edited the arguments for the scss-compiler:

-r sass-globbing --no-cache --update $FileName$:$FileNameWithoutExtension$.css

Now I can compile my scss recursively, but only if I make changes to the root file, where i do my import statement with the sass-globbing. Is it possible to trigger the scss-compiler on a change inside of one of the imported scss-partials, like before with globbing enabled?

Upvotes: 0

Views: 363

Answers (1)

lena
lena

Reputation: 93858

With "track only root files" enabled, the IDE follows SASS imports chain to find the 'main' file from a partial and pass it to compiler, so that no separate .css files are produced for partials and all changes are merged into the main .css file. But it knows nothing about file globbing and can't resolve imports when using glob patterns, that's why file watcher is not triggered

Upvotes: 0

Related Questions