Move Gulp config
This commit is contained in:
parent
2b28a547a6
commit
48284952a3
22
gulpfile.config.js
Normal file
22
gulpfile.config.js
Normal file
|
@ -0,0 +1,22 @@
|
|||
module.exports = function (plugins) {
|
||||
var config = {
|
||||
autoprefixer: {
|
||||
browsers: ["last 2 versions", "> 5%"]
|
||||
},
|
||||
bowerDir: 'vendor/bower_components',
|
||||
fontsDir: 'source/assets/fonts',
|
||||
js: {
|
||||
sourceDir: 'assets/js',
|
||||
outputDir: 'source/assets/js',
|
||||
pattern: '/**/*.js'
|
||||
},
|
||||
production: !!plugins.util.env.production,
|
||||
sass: {
|
||||
sourceDir: 'assets/sass',
|
||||
pattern: '/**/*.sass',
|
||||
outputDir: 'source/assets/css'
|
||||
}
|
||||
}
|
||||
|
||||
return config;
|
||||
}
|
20
gulpfile.js
20
gulpfile.js
|
@ -2,27 +2,9 @@
|
|||
|
||||
var gulp = require('gulp');
|
||||
var plugins = require('gulp-load-plugins')();
|
||||
var config = require('./gulpfile.config.js')(plugins);
|
||||
var del = require('del');
|
||||
|
||||
var config = {
|
||||
autoprefixer: {
|
||||
browsers: ["last 2 versions", "> 5%"]
|
||||
},
|
||||
bowerDir: 'vendor/bower_components',
|
||||
fontsDir: 'source/assets/fonts',
|
||||
js: {
|
||||
sourceDir: 'assets/js',
|
||||
outputDir: 'source/assets/js',
|
||||
pattern: '/**/*.js'
|
||||
},
|
||||
production: !!plugins.util.env.production,
|
||||
sass: {
|
||||
sourceDir: 'assets/sass',
|
||||
pattern: '/**/*.sass',
|
||||
outputDir: 'source/assets/css'
|
||||
}
|
||||
};
|
||||
|
||||
var app = {};
|
||||
|
||||
app.sass = function(paths, filename) {
|
||||
|
|
Reference in a new issue