sass(paths)
Compile SASS and SCSS files from paths.sass
to paths.build
. Maintains the same file names, but replacing the extention .s?ss
to .css
.
The compilation procedure for --production
:
- Compiles SASS
- Auto-prefixes styles
- Minifies compiled styles
The compilation procedure for non --production
:
- Compiles SASS
- Maintains comments
- Builds source maps
The css
task should run after sass has finished, if the output from sass is included in the css task.
var paths = {
sass: [
'private/stylesheets/*.s?ss',
'private/javascripts/my-angular-app/**/*.s?ss'
],
build: 'build/'
};
var gulp = require('gulp');
var taskMethods = require('gulpfile-ninecms');
var tasks = {
sass: function () { return taskMethods.sass(paths); }
};
gulp.task('sass', [], tasks.sass);