We need have *.hbs for input but *.html at output
ryuran opened this issue · comments
Hello,
It's can be a stupid question but.
How to change extension from src file to dest (.hbs to .html) ?
Thanks
Sure thing! You're looking for gulp-rename. You can use it before or after gulp-hb
to change the extensions. I like to put it close to the gulp.dest
when I can.
var gulp = require('gulp');
var hb = require('gulp-hb');
var rename = require('gulp-rename');
gulp.src('src/**/*.hbs')
.pipe(hb())
.pipe(rename({ extname: '.html' })
.pipe(gulp.dest('dest'))
Thank you for your answers.
I use gulp-rename and it's works.