Skip to content

Commit

Permalink
feat(SASSPlugin): Allow regexes to be passed to include/exclude certa…
Browse files Browse the repository at this point in the history
…in file patterns

Allow passing in cacheInclude and cacheExclude as options to the SASSPlugin, primarily so that filenames beginning with an underscore can be ignored during SASS/SCSS compilation, which is generally accepted to be a standard in SASS (http://sass-lang.com/guide#topic-4). These config values can be set in angular-cli-build.js thus:
    "sassCompiler": {
        "cacheExclude": [/\/_[^\/]+$/]
    }

This arguably closes issue #558 (#558)
  • Loading branch information
killface committed May 16, 2016
1 parent 88c77d6 commit 6b45099
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/broccoli/angular-broccoli-sass.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ class SASSPlugin extends Plugin {

options = options || {};
Plugin.call(this, inputNodes, {
cacheInclude: [/\.scss$/, /\.sass$/]
cacheInclude: options.cacheInclude || [/\.scss$/, /\.sass$/],
cacheExclude: options.cacheExclude || undefined
});
this.options = options;
}
Expand Down

0 comments on commit 6b45099

Please sign in to comment.