Answer the question
In order to leave comments, you need to log in
Why does gulp jade compile include files as separate html files?
Hello!
The documentation does not mention this, they say, you just write
include includes/head.jade in index.jade
And you get one compiled html file.
But for me, include/head.jade is compiled along with the folder in include/head.html, although I don’t need it, because this should be part of index.html and not a separate file
I'm using gulp-jade
Answer the question
In order to leave comments, you need to log in
I apologize for the archeology, but it seems to be canonical to do this:
gulp.task('jade', function () {
return gulp.src(['src/jade/**/*.jade','!src/jade/**/_*.jade'])
.pipe(newer('src/jade/**/*.jade'))
.pipe(plumber())
.pipe(jade({
pretty: '\t'
}))
.on('error', console.log)
.pipe(gulp.dest('./dist/'));
});
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question