PHP Task
Closed this issue · 3 comments
Hallo,
Es währe super wenn es noch möglich währe einen PHP Task hinzuzufügen.
Ich habe auch schon gesehen das es für das PHP minimieren eine Erweiterung gibt
(https://github.com/cedx/gulp-php-minify) leider kriege ich es nicht hin diese Erweiterung richtig bei gulp zu verwenden. Ich würde mich freuen wenn hier einer einen PHP Task richtig zum laufen bringen könnte.
// Compile .php to minify .php
const php = () => {
// Find PHP
return gulp.src(${src}/*.php
)
// Init Plumber
.pipe(plumber())
// Compile PHP
.pipe(htmlmin({
collapseWhitespace: true,
removeComments: true,
html5: true,
removeEmptyAttributes: true,
removeTagWhitespace: true,
sortAttributes: true,
sortClassName: true
}))
// Write everything to destination folder
.pipe(gulp.dest(${dest}
));
};
// Function to watch our Changes and refreash page
const watch = () => gulp.watch([${src}/*.html
,${src}/*.php
, ${src}/js/**/*.js
, ${src}/sass/**/*.sass
],
gulp.series(css, script, html, php, reload));
// All Tasks for this Project
const dev = gulp.series(css, script, html, php, serve, watch);
// Just Build the Project
const build = gulp.series(html, php, script, css);
@nisutec hat dir die Antwort von @jensen1206 geholfen? Oder gibt es das Problem immernoch?
Wegen Inaktivität wird das Issue geschlossen.