@alasdair/karma-scss-preprocessor
v5.0.0-3
Published
Karma preprocessor to compile SCSS on the fly with sass
Downloads
4,833
Maintainers
Readme
@alasdair/karma-scss-preprocessor
Karma preprocessor to compile Sass files on the fly with sass. In contrast of karma-sass-preprocessor, it does not write any intermediate file to the disk, and does not use any Gulp plugin.
Installation
npm install @alasdair/karma-scss-preprocessor sass --save-dev
This is a fork of karma-scss-preprocessor. The main difference is that sass
is used instead of node-sass
.
Note: since v5.0, sass is used as a peer dependency. That is why you need to install it along with this module.
Configuration
See sass options for more details.
module.exports = function (config) {
config.set({
// You may need to configure the plugin like this since
// older verisons of karma don't support scopes out of the box
plugins: [ '@alasdair/karma-scss-preprocessor', 'karma-*' ],
preprocessors: {
'src/**/*.scss': ['scss']
},
scssPreprocessor: {
options: {
sourceMap: true,
includePaths: ['bower_components']
}
}
});
};