Gulp header form package.json.
npm install -D @jswork/gulp-pkg-header
const header = require("@jswork/gulp-pkg-header");
// type: 'js'|'html'|'css'|'raw'
gulp.task('build' , function(){
return gulp.src("./src/*.js")
.pipe(header({ type: 'js' }))
.pipe(gulp.dest("dist"));
});
Code released under the MIT license.