20. The State of Front-End Tooling ‒ 2015
https://ashleynolan.co.uk/blog/frontend-tooling-survey-2015-results
21. The State of Front-End Tooling ‒ 2015
https://ashleynolan.co.uk/blog/frontend-tooling-survey-2015-results
Preprocessor Number of Votes Percentage
Sass 1297 63.95%
Less 308 15.19%
Stylus 76 3.75%
No Preprocessor 305 15.04%
Other 42 2.07%
• Update 12/10/2015
• 2028 responses
84. gulpfileの書き方
gulpfile.js
var gulp = require('gulp');
gulp.task('default', function() {
// place code for your default task here
});
タスク名
処理を書く
パッケージの読み込み
85. gulpfileの書き方
gulpfile.js
var gulp = require('gulp');
var sass = require('gulp-sass');
var sourcemaps = require('gulp-sourcemaps');
gulp.task('sass', function () {
return gulp.src('./sass/**/*.scss')
.pipe(sourcemaps.init())
.pipe(sass().on('error', sass.logError))
.pipe(sourcemaps.write())
.pipe(gulp.dest('./css'));
});
タスク名
処理を書く
.pipeでつなぐ
パッケージの読み込み
86. gulpfileの書き方
gulpfile.js
var gulp = require('gulp');
var sass = require('gulp-sass');
var sourcemaps = require('gulp-sourcemaps');
gulp.task('sass', function () {
return gulp.src('./sass/**/*.scss')
.pipe(sourcemaps.init())
.pipe(sass().on('error', sass.logError))
.pipe(sourcemaps.write())
.pipe(gulp.dest('./css'));
});