我有带bower的bootstrap的最新版本。我正在使用gulp任务将其传递给css。在我的style.scss我正在运行如何在自举中启用flex-true scss 4
@import "bootstrap";
@import "font-awesome";
所有这些都是工作文件。我正在阅读有关如何在此处启用Flexbox的文档:http://v4-alpha.getbootstrap.com/getting-started/flexbox/
该文档说:打开_variables.scss文件并找到$ enable-flex变量。这是否意味着我需要进入bower_components/bootstrap/scss /并找到_variables.scss,并在那里更改它?
我一口我已经引导定义为./bower_components/bootstrap/scss
如何处理这种不重写,应有尽有,而且更重要的是,我怎么能弯曲正确?我只是在这里添加我的gulp文件,以防万一它需要。
const gulp = require('gulp'),
sass = require('gulp-sass'),
autoprefix = require('gulp-autoprefixer'),
notify = require("gulp-notify"),
bower = require('gulp-bower');
let config = {
bootstrapDir: './bower_components/bootstrap',
fontawesomeDir: './bower_components/font-awesome',
publicDir: './public',
bowerDir: './bower_components'
}
gulp.task('bower', function() {
return bower()
.pipe(gulp.dest(config.bowerDir))
});
gulp.task('fonts', function() {
return gulp.src(config.bowerDir + '/font-awesome/fonts/**.*')
.pipe(gulp.dest('./public/assets/fonts'));
});
gulp.task('css', function() {
return gulp.src('./public/assets/sass/style.scss')
.pipe(sass({
includePaths: [config.bootstrapDir + '/scss', config.fontawesomeDir + '/scss'],
}))
.pipe(gulp.dest(config.publicDir + '/assets/css'));
});
// Watch task
gulp.task('watch',function() {
gulp.watch('./public/assets/sass/**/*.scss', ['css']);
});
gulp.task('default', ['bower', 'fonts', 'css']);