There is a 1-pager website. It consists of index.php
that includes numerous sections (other PHP files). Each of the section includes links to JavaScript files.
Questions: is it possible to generate a single minified PHP file, that will have a single link to a single minified JS file (something similar to https://www.npmjs.com/package/gulp-sass
)?
I have managed to resolve this issue myself. It is possible to achieve the desired result with just 2 tools:
With concat I was able to concatenate all *.js files into
logic.js
like this:With ghfi I was able to include all included PHPs and then minify the result into a single
index.php
:Had to include child-PHP files indside the parent one like this:
{{ fileInclude 'src/foo.php' }}
PS: the person who down-voted my question - you are truly
amazing.