maoberlehner / node-sass-magic-importer

Custom node-sass importer for selector specific imports, module importing, globbing support and importing files only once.
MIT License
292 stars 28 forks source link

Multi level filter imports #173

Open maoberlehner opened 6 years ago

maoberlehner commented 6 years ago

Selector filtering goes only one level deep. This means, if you're importing a file with selector filtering which is importing other files, those files are not filtered but imported as is. On a technical level, there is no good solution for this problem. One possibility would be to just pass the filters to all imports in the line but this carries the risk of filtering selectors on which one of the imported files might depend and therefore break the import. I might add this as an optional feature (which can be activated on demand) in the future – let me know if you're interested in multi level filter imports.

gilsdav commented 5 years ago

@maoberlehner Hello, I really need this feature for my build tool. I filter on a main file and all sub imports are included in all files. Projects became huge. This feature will help us. +1000